> ## Documentation Index
> Fetch the complete documentation index at: https://docs.validio.io/llms.txt
> Use this file to discover all available pages before exploring further.

# validio_sdk.resource.windows module

> Window configuration.

Window configuration.

### Duration

```python
class validio_sdk.resource.windows.Duration(*, length: int, unit: DurationTimeUnit)
```

**Parameters**

**length** `int` *required*

**unit** `DurationTimeUnit` *required*

Bases: `Diffable`

Duration defines a span of time, represented by a length and unit of the duration. For example, a length of 5 and unit of Month represents 5 months.

### DurationTimeUnit

```python
class validio_sdk.resource.windows.DurationTimeUnit(*values)
```

Bases: `str`, `Enum`

A unit of time.

#### DAY

```python
DAY = 'DAY'
```

#### HOUR

```python
HOUR = 'HOUR'
```

#### MINUTE

```python
MINUTE = 'MINUTE'
```

#### MONTH

```python
MONTH = 'MONTH'
```

#### WEEK

```python
WEEK = 'WEEK'
```

### FixedBatchWindow

```python
class validio_sdk.resource.windows.FixedBatchWindow(*, name: str, source: Source, data_time_field: str, batch_size: int, segmented_batching: bool = False, batch_timeout_secs: int | None = None, display_name: str | None = None, segment_retention_period_days: int | None = None, ignore_changes: bool = False, recreate_on_change: bool = False)
```

**Parameters**

**name** `str` *required*

**source** `Source` *required*

**data\_time\_field** `str` *required*

**batch\_size** `int` *required*

**segmented\_batching** `bool`

**batch\_timeout\_secs** `int | None`

**display\_name** `str | None`

**segment\_retention\_period\_days** `int | None`

**ignore\_changes** `bool`

**recreate\_on\_change** `bool`

Bases: [`Window`](https://docs.validio.io/v10.2/sdk-reference/validio_sdk.resource#window "validio_sdk.resource.windows.Window")

A FixedBatch window resource.

See [About Windows](https://docs.validio.io/v10.2/docs/windows.md).

#### data\_time\_field

```python
data_time_field: str
```

### GlobalWindow

```python
class validio_sdk.resource.windows.GlobalWindow(*, name: str, source: Source, display_name: str | None = None, segment_retention_period_days: int | None = None, ignore_changes: bool = False, recreate_on_change: bool = False)
```

**Parameters**

**name** `str` *required*

**source** `Source` *required*

**display\_name** `str | None`

**segment\_retention\_period\_days** `int | None`

**ignore\_changes** `bool`

**recreate\_on\_change** `bool`

Bases: [`Window`](https://docs.validio.io/v10.2/sdk-reference/validio_sdk.resource#window "validio_sdk.resource.windows.Window")

A Global window resource.

Represent a single window spanning over all the data.

### PartitionFilter

```python
class validio_sdk.resource.windows.PartitionFilter(*, field: str, lookback: Duration)
```

**Parameters**

**field** `str` *required*

**lookback** `Duration` *required*

Bases: `Diffable`

For a partitioned table, this provides configuration to add a qualifying filter on the value of the partitioning column. This is useful when the the configured datatime field of the tumbling window is not the same as the partitioning column of the table, in which case - a partition filter helps prune out irrelevant partitions in queries.

### TumblingWindow

```python
class validio_sdk.resource.windows.TumblingWindow(*, name: str, source: Source, data_time_field: str, window_size: int, time_unit: WindowTimeUnit, window_timeout_disabled: bool = False, display_name: str | None = None, segment_retention_period_days: int | None = None, lookback: Duration | None = None, partition_filter: PartitionFilter | None = None, ignore_changes: bool = False, recreate_on_change: bool = False)
```

**Parameters**

**name** `str` *required*

**source** `Source` *required*

**data\_time\_field** `str` *required*

**window\_size** `int` *required*

**time\_unit** `WindowTimeUnit` *required*

**window\_timeout\_disabled** `bool`

**display\_name** `str | None`

**segment\_retention\_period\_days** `int | None`

**lookback** `Duration | None`

**Type:** `Duration | None`

**partition\_filter** `PartitionFilter | None`

**Type:** `PartitionFilter | None`

**ignore\_changes** `bool`

**recreate\_on\_change** `bool`

Bases: [`Window`](https://docs.validio.io/v10.2/sdk-reference/validio_sdk.resource#window "validio_sdk.resource.windows.Window")

A Tumbling window resource.

#### data\_time\_field

```python
data_time_field: str
```

#### window\_size

```python
window_size: int
```

### Window

```python
class validio_sdk.resource.windows.Window(name: str, source: Source, display_name: str | None, segment_retention_period_days: int | None = None, ignore_changes: bool = False, recreate_on_change: bool = False)
```

**Parameters**

**name** `str` *required*

**source** `Source` *required*

**display\_name** `str | None` *required*

**segment\_retention\_period\_days** `int | None`

**ignore\_changes** `bool`

**recreate\_on\_change** `bool`

Bases: `Resource`

Base class for a window resource.

See [About Windows](https://docs.validio.io/v10.2/docs/windows.md).

#### resource\_class\_name()

```python
resource_class_name() → str
```

**Returns:** `str`

Returns the base class name.

#### source\_name

```python
source_name: str
```

### WindowTimeUnit

```python
class validio_sdk.resource.windows.WindowTimeUnit(*values)
```

Bases: `str`, `Enum`

Unit of window time.

#### DAY

```python
DAY = 'DAY'
```

#### HOUR

```python
HOUR = 'HOUR'
```

#### MINUTE

```python
MINUTE = 'MINUTE'
```

#### MONTH

```python
MONTH = 'MONTH'
```

#### WEEK

```python
WEEK = 'WEEK'
```
