Class WindowAsyncValueState<W>
java.lang.Object
org.apache.flink.table.runtime.operators.window.async.tvf.state.WindowAsyncValueState<W>
- All Implemented Interfaces:
WindowAsyncState<W>
A wrapper of
ValueState which is easier to update based on window namespace.-
Constructor Summary
ConstructorsConstructorDescriptionWindowAsyncValueState(org.apache.flink.runtime.state.v2.internal.InternalValueState<org.apache.flink.table.data.RowData, W, org.apache.flink.table.data.RowData> windowState) -
Method Summary
Modifier and TypeMethodDescriptionorg.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<Void>asyncUpdate(W window, org.apache.flink.table.data.RowData value) Update the state with the given value under current key and the given window.org.apache.flink.api.common.state.v2.StateFuture<org.apache.flink.table.data.RowData>asyncValue(W window) Returns the current value for the state under current key and the given window.
-
Constructor Details
-
WindowAsyncValueState
public WindowAsyncValueState(org.apache.flink.runtime.state.v2.internal.InternalValueState<org.apache.flink.table.data.RowData, W, org.apache.flink.table.data.RowData> windowState)
-
-
Method Details
-
asyncClear
Description copied from interface:WindowAsyncStateRemoves the value mapped under current key and the given window.- Specified by:
asyncClearin interfaceWindowAsyncState<W>
-
asyncValue
public org.apache.flink.api.common.state.v2.StateFuture<org.apache.flink.table.data.RowData> asyncValue(W window) throws IOException Returns the current value for the state under current key and the given window.- Throws:
IOException
-
asyncUpdate
public org.apache.flink.api.common.state.v2.StateFuture<Void> asyncUpdate(W window, org.apache.flink.table.data.RowData value) throws IOException Update the state with the given value under current key and the given window.- Parameters:
window- the window namespace.value- the new value for the state.- Throws:
IOException
-