com.google.cloud.dataflow.sdk.transforms.windowing

## Class InvalidWindows<W extends BoundedWindow>

- java.lang.Object
- - com.google.cloud.dataflow.sdk.transforms.windowing.WindowFn<Object,W>
  - - com.google.cloud.dataflow.sdk.transforms.windowing.InvalidWindows<W>

Type Parameters:
  `W` - window type

All Implemented Interfaces:
  HasDisplayData, Serializable

    public class InvalidWindows<W extends BoundedWindow>
    extends WindowFn<Object,W>

A `WindowFn` that represents an invalid pipeline state.

See Also:
  Serialized Form

### Nested Class Summary

### Nested classes/interfaces inherited from class com.google.cloud.dataflow.sdk.transforms.windowing.WindowFn

`WindowFn.AssignContext, WindowFn.MergeContext`

### Constructor Summary

Constructors
Constructor and Description
`InvalidWindows(String cause, WindowFn<?,W> originalWindowFn)`

### Method Summary

All Methods Instance Methods Concrete Methods
`Collection<W>` `assignWindows(WindowFn.AssignContext c)` Given a timestamp and element, returns the set of windows into which it should be placed.
`String` `getCause()` Returns the reason that this `WindowFn` is invalid.
`WindowFn<?,W>` `getOriginalWindowFn()` Returns the original windowFn that this InvalidWindows replaced.
`Instant` `getOutputTime(Instant inputTimestamp, W window)`
`W` `getSideInputWindow(BoundedWindow window)` Returns the window of the side input corresponding to the given window of the main input.
`boolean` `isCompatible(WindowFn<?,?> other)` `InvalidWindows` objects with the same `originalWindowFn` are compatible.
`void` `mergeWindows(WindowFn.MergeContext c)` Does whatever merging of windows is necessary.
`Coder<W>` `windowCoder()` Returns the `Coder` used for serializing the windows used by this windowFn.

### Methods inherited from class com.google.cloud.dataflow.sdk.transforms.windowing.WindowFn

`assignsToSingleWindow, getOutputTimeFn, isNonMerging, populateDisplayData`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### InvalidWindows

    public InvalidWindows(String cause,
                          WindowFn<?,W> originalWindowFn)

### Method Detail

#### getCause

    public String getCause()

Returns the reason that this `WindowFn` is invalid.

#### getOriginalWindowFn

    public WindowFn<?,W> getOriginalWindowFn()

Returns the original windowFn that this InvalidWindows replaced.

#### assignWindows

    public Collection<W> assignWindows(WindowFn.AssignContext c)

Description copied from class: `WindowFn`
Given a timestamp and element, returns the set of windows into which it should be placed.

Specified by:
  `assignWindows` in class `WindowFn<Object,W extends BoundedWindow>`

#### mergeWindows

    public void mergeWindows(WindowFn.MergeContext c)

Description copied from class: `WindowFn`
Does whatever merging of windows is necessary.

See `MergeOverlappingIntervalWindows.mergeWindows(com.google.cloud.dataflow.sdk.transforms.windowing.WindowFn<?, com.google.cloud.dataflow.sdk.transforms.windowing.IntervalWindow>.MergeContext)` for an example of how to override this method.

Specified by:
  `mergeWindows` in class `WindowFn<Object,W extends BoundedWindow>`

#### windowCoder

    public Coder<W> windowCoder()

Description copied from class: `WindowFn`
Returns the `Coder` used for serializing the windows used by this windowFn.

Specified by:
  `windowCoder` in class `WindowFn<Object,W extends BoundedWindow>`

#### isCompatible

    public boolean isCompatible(WindowFn<?,?> other)

`InvalidWindows` objects with the same `originalWindowFn` are compatible.

Specified by:
  `isCompatible` in class `WindowFn<Object,W extends BoundedWindow>`

#### getSideInputWindow

    public W getSideInputWindow(BoundedWindow window)

Description copied from class: `WindowFn`
Returns the window of the side input corresponding to the given window of the main input.

Authors of custom `WindowFn`s should override this.

Specified by:
  `getSideInputWindow` in class `WindowFn<Object,W extends BoundedWindow>`

#### getOutputTime

    public Instant getOutputTime(Instant inputTimestamp,
                                 W window)

Overrides:
  `getOutputTime` in class `WindowFn<Object,W extends BoundedWindow>`