Class WindowListAsyncState<W>
- java.lang.Object
-
- org.apache.flink.table.runtime.operators.window.tvf.asyncprocessing.state.WindowListAsyncState<W>
-
- All Implemented Interfaces:
WindowAsyncState<W>
public final class WindowListAsyncState<W> extends Object implements WindowAsyncState<W>
A wrapper ofListStatewhich is easier to update based on window namespace.
-
-
Constructor Summary
Constructors Constructor Description WindowListAsyncState(org.apache.flink.runtime.state.v2.internal.InternalListState<org.apache.flink.table.data.RowData,W,org.apache.flink.table.data.RowData> windowState)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.flink.api.common.state.v2.StateFuture<Void>asyncAdd(W window, org.apache.flink.table.data.RowData value)Updates the operator state accessible by#asyncGet(W)by adding the given value to the list of values.org.apache.flink.api.common.state.v2.StateFuture<Void>asyncClear(W window)Removes the value mapped under current key and the given window.org.apache.flink.api.common.state.v2.StateFuture<org.apache.flink.api.common.state.v2.StateIterator<org.apache.flink.table.data.RowData>>asyncGet(W window)
-
-
-
Constructor Detail
-
WindowListAsyncState
public WindowListAsyncState(org.apache.flink.runtime.state.v2.internal.InternalListState<org.apache.flink.table.data.RowData,W,org.apache.flink.table.data.RowData> windowState)
-
-
Method Detail
-
asyncClear
public org.apache.flink.api.common.state.v2.StateFuture<Void> asyncClear(W window)
Description copied from interface:WindowAsyncStateRemoves the value mapped under current key and the given window.- Specified by:
asyncClearin interfaceWindowAsyncState<W>
-
asyncGet
public org.apache.flink.api.common.state.v2.StateFuture<org.apache.flink.api.common.state.v2.StateIterator<org.apache.flink.table.data.RowData>> asyncGet(W window)
-
asyncAdd
public org.apache.flink.api.common.state.v2.StateFuture<Void> asyncAdd(W window, org.apache.flink.table.data.RowData value)
Updates the operator state accessible by#asyncGet(W)by adding the given value to the list of values. The next time#asyncGet(W)is called (for the same state partition) the returned state will represent the updated list.If null is passed in, the state value will remain unchanged.
- Parameters:
window- The namespace for the state.value- The new value for the state.
-
-