|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectde.unidu.is.util.PropertyMap
de.unidu.is.util.DelegatedPropertyMap
This class delegates all calls to another map. This map implementation can be initialised by another map. The keys of this initialisation map are stored separately, so that these entries can be distinguished from the "ordinary" entries lateron.
| Nested Class Summary |
| Nested classes inherited from class java.util.Map |
java.util.Map.Entry |
| Field Summary | |
protected java.util.Set |
initKeys
Set containing initial keys. |
protected java.util.Map |
map
Map implementation to which all calls are delegated. |
| Fields inherited from class de.unidu.is.util.PropertyMap |
multipleValues |
| Constructor Summary | |
DelegatedPropertyMap(java.util.Map map)
Creates a new instance. |
|
DelegatedPropertyMap(java.util.Map map,
boolean multipleValues)
Creates a new instance. |
|
| Method Summary | |
protected void |
changed()
Calls whenever the map is changed. |
void |
clear()
Removes all entries. |
boolean |
containsKey(java.lang.Object key)
|
boolean |
containsValue(java.lang.Object value)
|
java.util.Set |
entrySet()
|
boolean |
equals(java.lang.Object obj)
|
java.lang.Object |
get(java.lang.Object key)
|
java.util.List |
getAll(java.lang.Object key)
Returns a list with all values stored for the specified key. |
java.util.Set |
getInitKeys()
Returns the initial keys. |
java.util.Map |
getMap()
Returns the map to which calls are delegated. |
int |
hashCode()
|
void |
init(java.util.Map init)
Inits the map by setting the initial keys and values. |
boolean |
isEmpty()
|
java.util.Set |
keySet()
|
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value)
|
void |
putAll(java.util.Map t)
|
java.lang.Object |
putInitial(java.lang.Object key,
java.lang.Object value)
Sets an initial value which can be distinguished from "ordinary" entries lateron. |
java.lang.Object |
putNoChange(java.lang.Object key,
java.lang.Object value)
Puts the (key,vaue) pair into the map without calling the changed() method. |
java.lang.Object |
remove(java.lang.Object key)
|
void |
remove(java.lang.Object key,
java.lang.Object value)
Removes the specified value for the specified key. |
void |
setInitKeys(java.util.Set initKeys)
Sets the initial keys. |
void |
setMap(java.util.Map map)
Sets the map to which calls are delegated. |
int |
size()
|
java.lang.String |
toString()
|
java.util.Collection |
values()
|
| Methods inherited from class de.unidu.is.util.PropertyMap |
addDouble, addDouble, addDouble, addInt, addInt, addInt, apply, convertString, divDouble, divDouble, divDouble, divInt, divInt, divInt, getBoolean, getDouble, getInt, getLength, getLong, getMaxDouble, getMaxKey, getMinDouble, getString, getString, getSum, hasMultipleValues, inc, initDouble, isMultipleValues, multDouble, multDouble, multDouble, multDouble, multInt, multInt, multInt, normalizeLength, removeCloseToZero, removeZero, set, setBoolean, setDouble, setInt, setLong, setMultipleValues, setString, subDouble, subDouble, subDouble, subInt, subInt, subInt |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected java.util.Map map
protected java.util.Set initKeys
| Constructor Detail |
public DelegatedPropertyMap(java.util.Map map)
map - to which calls are delegated
public DelegatedPropertyMap(java.util.Map map,
boolean multipleValues)
map - to which calls are delegatedmultipleValues - values if true, multiple values can be hold for a key| Method Detail |
public void init(java.util.Map init)
init - map for initialisation (may be null)protected void changed()
Subclasses can override this method.
public void clear()
public boolean containsKey(java.lang.Object key)
public boolean containsValue(java.lang.Object value)
public java.util.Set entrySet()
public boolean equals(java.lang.Object obj)
public java.lang.Object get(java.lang.Object key)
public int hashCode()
public boolean isEmpty()
public java.util.Set keySet()
public java.lang.Object put(java.lang.Object key,
java.lang.Object value)
public java.lang.Object putNoChange(java.lang.Object key,
java.lang.Object value)
changed() method.
key - keyvalue - value for the key
public java.lang.Object putInitial(java.lang.Object key,
java.lang.Object value)
key - entry keyvalue - entry value
null if no value is availablepublic void putAll(java.util.Map t)
public java.lang.Object remove(java.lang.Object key)
public int size()
public java.lang.String toString()
public java.util.Collection values()
public java.util.List getAll(java.lang.Object key)
PropertyMap
getAll in class PropertyMapkey - property key
public void remove(java.lang.Object key,
java.lang.Object value)
PropertyMap
remove in class PropertyMapkey - property keyvalue - value to be removedpublic java.util.Map getMap()
public void setMap(java.util.Map map)
map - map to which calls are delegatedpublic void setInitKeys(java.util.Set initKeys)
initKeys - initial keyspublic java.util.Set getInitKeys()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||