- java.lang.Object
-
- swim.streamlet.AbstractMapOutlet<K,V,Map<K,V>>
-
- swim.streamlet.MapInput<K,V>
-
-
Field Summary
Fields Modifier and Type Field Description protected HashTrieMap<K,V>
state
-
Fields inherited from class swim.streamlet.AbstractMapOutlet
effects, outlets, outputs, version
-
-
Constructor Summary
Constructors Constructor Description MapInput()
MapInput(HashTrieMap<K,V> state)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
containsKey(K key)
Returnstrue
if the current state of thisMapOutlet
contains the givenkey
; otherwise returnsfalse
.Map<K,V>
get()
Returns the current state of thisOutlet
.V
get(K key)
Returns the value assocaited with the givenkey
in the current state of thisMapOutlet
, if defined; otherwise returnsnull
.Iterator<K>
keyIterator()
Returns anIterator
over the keys in the current state of thisMapOutlet
.V
put(K key, V newValue)
boolean
removeKey(K key)
-
Methods inherited from class swim.streamlet.AbstractMapOutlet
bindOutput, decohereInput, decohereInputKey, didDecohereInput, didDecohereInputKey, didRecohereInput, didRecohereInputKey, disconnectInputs, disconnectOutputs, onDecohereInput, onDecohereInputKey, onRecohereInput, onRecohereInputKey, outlet, outputIterator, recohereInput, recohereInputKey, unbindOutput, unbindOutputs, willDecohereInput, willDecohereInputKey, willRecohereInput, willRecohereInputKey
-
-
-
-
Field Detail
-
state
protected HashTrieMap<K,V> state
-
-
Constructor Detail
-
MapInput
public MapInput(HashTrieMap<K,V> state)
-
MapInput
public MapInput()
-
-
Method Detail
-
containsKey
public boolean containsKey(K key)
Description copied from interface:MapOutlet
Returnstrue
if the current state of thisMapOutlet
contains the givenkey
; otherwise returnsfalse
.- Specified by:
containsKey
in interfaceMapOutlet<K,V,Map<K,V>>
- Specified by:
containsKey
in classAbstractMapOutlet<K,V,Map<K,V>>
-
get
public V get(K key)
Description copied from interface:MapOutlet
Returns the value assocaited with the givenkey
in the current state of thisMapOutlet
, if defined; otherwise returnsnull
.
-
removeKey
public boolean removeKey(K key)
-
get
public Map<K,V> get()
Description copied from interface:Outlet
Returns the current state of thisOutlet
.
-
-