Package org.apache.flink.state.api.input
Class MultiStateKeyIterator<K>
- java.lang.Object
-
- org.apache.flink.state.api.input.MultiStateKeyIterator<K>
-
- Type Parameters:
K- Type of the key by which state is keyed.
- All Implemented Interfaces:
AutoCloseable,Iterator<K>,org.apache.flink.util.CloseableIterator<K>
@Internal public final class MultiStateKeyIterator<K> extends Object implements org.apache.flink.util.CloseableIterator<K>
An iterator for reading all keys in a state backend across multiple partitioned states.To read unique keys across all partitioned states callers must invoke
remove().
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.flink.util.CloseableIterator
org.apache.flink.util.CloseableIterator.IteratorAdapter<E extends Object>
-
-
Constructor Summary
Constructors Constructor Description MultiStateKeyIterator(List<? extends org.apache.flink.api.common.state.StateDescriptor<?,?>> descriptors, org.apache.flink.runtime.state.KeyedStateBackend<K> backend)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()booleanhasNext()Knext()voidremove()Removes the current key from ALL known states in the state backend.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-
-
-
Method Detail
-
remove
public void remove()
Removes the current key from ALL known states in the state backend.
-
close
public void close() throws Exception- Specified by:
closein interfaceAutoCloseable- Throws:
Exception
-
-