public interface HasContext
Modifier and Type | Method and Description |
---|---|
int |
contextSize() |
void |
copyContextFrom(HasContext other)
Copies the context from the given context holder to this context holder.
|
ImmutableOpenMap<Object,Object> |
getContext() |
<V> V |
getFromContext(Object key) |
<V> V |
getFromContext(Object key,
V defaultValue) |
boolean |
hasInContext(Object key)
Checks if the context contains an entry with the given key
|
boolean |
isContextEmpty()
Checks if the context is empty.
|
void |
putAllInContext(com.carrotsearch.hppc.ObjectObjectAssociativeContainer<Object,Object> map)
Attaches the given values to the context
|
<V> V |
putInContext(Object key,
Object value)
Attaches the given value to the context.
|
<V> V putInContext(Object key, Object value)
null
if there was none.void putAllInContext(com.carrotsearch.hppc.ObjectObjectAssociativeContainer<Object,Object> map)
<V> V getFromContext(Object key)
putInContext(Object, Object)
<V> V getFromContext(Object key, V defaultValue)
defaultValue
- The default value that should be returned for the given key, if no
value is currently associated with it.putInContext(Object, Object)
boolean hasInContext(Object key)
int contextSize()
boolean isContextEmpty()
ImmutableOpenMap<Object,Object> getContext()
void copyContextFrom(HasContext other)
Copyright © 2009–2016. All rights reserved.