public class PropertyMap extends Properties
When this is cloned it will deep copy not only the model object map, but also each clonable member inside the map.
Subclassing is supported, a hook can be implemented to provide conditional inclusion in the map. By default - all properties are accepted, so set is never propagated.
This class is not multithread safe.
Modifier and Type | Field and Description |
---|---|
private static CloneHelper |
cloneHelper |
private Map<com.yahoo.processing.request.CompoundName,Object> |
properties
The properties of this
|
Constructor and Description |
---|
PropertyMap() |
Modifier and Type | Method and Description |
---|---|
PropertyMap |
clone() |
static Object |
clone(Object object)
Clones this object if it is clonable, and the clone is public.
|
Object |
get(com.yahoo.processing.request.CompoundName name,
Map<String,String> context,
com.yahoo.processing.request.Properties substitution) |
Map<String,Object> |
listProperties(com.yahoo.processing.request.CompoundName path,
Map<String,String> context,
com.yahoo.processing.request.Properties substitution) |
Map<com.yahoo.processing.request.CompoundName,Object> |
propertyMap()
Returns a direct reference to the map containing the properties set in this instance.
|
void |
set(com.yahoo.processing.request.CompoundName name,
Object value,
Map<String,String> context) |
protected boolean |
shouldSet(com.yahoo.processing.request.CompoundName name,
Object value)
Return true if this value should be set in this map, false if the set should be propagated instead
This default implementation always returns true.
|
chained, getParentQuery, setParentQuery
asBoolean, asDouble, asInteger, asLong, asString, chain, cloneMap, get, get, get, get, get, get, get, getBoolean, getBoolean, getBoolean, getBoolean, getDouble, getDouble, getDouble, getDouble, getInstance, getInteger, getInteger, getInteger, getInteger, getLong, getLong, getLong, getLong, getString, getString, getString, getString, listProperties, listProperties, listProperties, listProperties, listProperties, listProperties, listProperties, set, set, set
private static final CloneHelper cloneHelper
public void set(com.yahoo.processing.request.CompoundName name, Object value, Map<String,String> context)
set
in class com.yahoo.processing.request.Properties
protected boolean shouldSet(com.yahoo.processing.request.CompoundName name, Object value)
public Object get(com.yahoo.processing.request.CompoundName name, Map<String,String> context, com.yahoo.processing.request.Properties substitution)
get
in class com.yahoo.processing.request.Properties
public Map<com.yahoo.processing.request.CompoundName,Object> propertyMap()
public PropertyMap clone()
clone
in class Properties
public Map<String,Object> listProperties(com.yahoo.processing.request.CompoundName path, Map<String,String> context, com.yahoo.processing.request.Properties substitution)
listProperties
in class com.yahoo.processing.request.Properties
Copyright © 2018. All rights reserved.