public interface NodeMetaDataHandler
Modifier and Type | Method and Description |
---|---|
default void |
copyNodeMetaData(NodeMetaDataHandler other)
Copies all node meta data from the other node to this one
|
Map<?,?> |
getMetaDataMap() |
default Map<?,?> |
getNodeMetaData()
Returns an unmodifiable view of the current node metadata.
|
default <T> T |
getNodeMetaData(Object key)
Gets the node meta data.
|
default <T> T |
getNodeMetaData(Object key,
Function<?,? extends T> valFn)
Gets the node meta data.
|
default Object |
putNodeMetaData(Object key,
Object value)
Sets the node meta data but allows overwriting values.
|
default void |
removeNodeMetaData(Object key)
Removes a node meta data entry.
|
void |
setMetaDataMap(Map<?,?> metaDataMap) |
default void |
setNodeMetaData(Object key,
Object value)
Sets the node meta data.
|
default <T> T getNodeMetaData(Object key)
key
- the meta data keydefault <T> T getNodeMetaData(Object key, Function<?,? extends T> valFn)
key
- the meta data keyvalFn
- the meta data value supplierdefault void copyNodeMetaData(NodeMetaDataHandler other)
other
- the other nodedefault void setNodeMetaData(Object key, Object value)
key
- the meta data keyvalue
- the meta data valueGroovyBugError
- if key is null or there is already meta
data under that keydefault Object putNodeMetaData(Object key, Object value)
key
- the meta data keyvalue
- the meta data valueGroovyBugError
- if key is nulldefault void removeNodeMetaData(Object key)
key
- the meta data keyGroovyBugError
- if the key is nulldefault Map<?,?> getNodeMetaData()
Map<?,?> getMetaDataMap()
void setMetaDataMap(Map<?,?> metaDataMap)