K - The type of the key.N - The type of the namespace.V - The type of the value.public class FsListState<K,N,V> extends AbstractFsState<K,N,ArrayList<V>,org.apache.flink.api.common.state.ListState<V>,org.apache.flink.api.common.state.ListStateDescriptor<V>> implements org.apache.flink.api.common.state.ListState<V>
ListState that is snapshotted
into files.| Modifier and Type | Class and Description |
|---|---|
static class |
FsListState.Snapshot<K,N,V> |
currentKey, currentNamespace, currentNSState, keySerializer, namespaceSerializer, state, stateDesc, stateSerializer| Constructor and Description |
|---|
FsListState(FsStateBackend backend,
org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer,
org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer,
org.apache.flink.api.common.state.ListStateDescriptor<V> stateDesc)
Creates a new and empty partitioned state.
|
FsListState(FsStateBackend backend,
org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer,
org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer,
org.apache.flink.api.common.state.ListStateDescriptor<V> stateDesc,
HashMap<N,Map<K,ArrayList<V>>> state)
Creates a new key/value state with the given state contents.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(V value) |
KvStateSnapshot<K,N,org.apache.flink.api.common.state.ListState<V>,org.apache.flink.api.common.state.ListStateDescriptor<V>,FsStateBackend> |
createHeapSnapshot(org.apache.flink.core.fs.Path filePath) |
Iterable<V> |
get() |
snapshotclear, dispose, getKeySerializer, getNamespaceSerializer, setCurrentKey, setCurrentNamespace, sizepublic FsListState(FsStateBackend backend, org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, org.apache.flink.api.common.state.ListStateDescriptor<V> stateDesc)
keySerializer - The serializer for the key.stateDesc - The state identifier for the state. This contains name
and can create a default state value.backend - The file system state backend backing snapshots of this statepublic FsListState(FsStateBackend backend, org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, org.apache.flink.api.common.state.ListStateDescriptor<V> stateDesc, HashMap<N,Map<K,ArrayList<V>>> state)
keySerializer - The serializer for the key.namespaceSerializer - The serializer for the namespace.stateDesc - The state identifier for the state. This contains name
and can create a default state value.state - The map of key/value pairs to initialize the state with.backend - The file system state backend backing snapshots of this statepublic void add(V value)
public KvStateSnapshot<K,N,org.apache.flink.api.common.state.ListState<V>,org.apache.flink.api.common.state.ListStateDescriptor<V>,FsStateBackend> createHeapSnapshot(org.apache.flink.core.fs.Path filePath)
createHeapSnapshot in class AbstractFsState<K,N,ArrayList<V>,org.apache.flink.api.common.state.ListState<V>,org.apache.flink.api.common.state.ListStateDescriptor<V>>Copyright © 2014–2016 The Apache Software Foundation. All rights reserved.