|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.alfresco.util.OneToManyHashBiMap
public class OneToManyHashBiMap
| Constructor Summary | |
|---|---|
OneToManyHashBiMap()
|
|
| Method Summary | |
|---|---|
void |
clear()
|
boolean |
containsKey(java.lang.Object key)
|
boolean |
containsSingleValue(java.lang.Object value)
This method returns true if any of the value sets in the
OneToManyMap contains an equivalent object to the value
parameter, where equivalence is determined using the
equals(Object) method. |
boolean |
containsValue(java.lang.Object value)
|
java.util.Set |
entries()
This method is similar to the java.util.Map.entrySet()
method, however the entries returned map from a key to a value, rather
than from a key(K) to a value(V) rather than
froma key(K) to a set of values(Set<V>). |
java.util.Set |
entrySet()
|
java.util.Collection |
flatValues()
Returns a Collection of all the values in the map. |
java.util.Set |
get(java.lang.Object key)
|
java.lang.Object |
getKey(java.lang.Object value)
Returns the key, if any, for the specified value. |
boolean |
isEmpty()
|
java.util.Set |
keySet()
|
java.util.Set |
put(java.lang.Object key,
java.util.Set values)
|
void |
putAll(java.util.Map m)
|
void |
putAllSingleValues(java.util.Map m)
This method is similar to java.utilMap.putAll(Map m),
however the map specified is from keys to values instead of keys to sets
of values. |
java.lang.Object |
putSingleValue(java.lang.Object key,
java.lang.Object value)
This method is similar to the method java.util.Map.put(K, V)
, however it allows the user to add a single value to the map rather than
adding a java.util.Set containing one or more values. |
java.util.Set |
remove(java.lang.Object key)
|
java.lang.Object |
removeValue(java.lang.Object value)
Removes the specified value from the OneToManyBiMap. |
int |
size()
|
java.util.Collection |
values()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface java.util.Map |
|---|
equals, hashCode |
| Methods inherited from interface java.util.Map |
|---|
equals, hashCode |
| Constructor Detail |
|---|
public OneToManyHashBiMap()
| Method Detail |
|---|
public void clear()
clear in interface java.util.Mappublic boolean containsKey(java.lang.Object key)
containsKey in interface java.util.Mappublic boolean containsValue(java.lang.Object value)
containsValue in interface java.util.Mappublic boolean containsSingleValue(java.lang.Object value)
OneToManyMaptrue if any of the value sets in the
OneToManyMap contains an equivalent object to the value
parameter, where equivalence is determined using the
equals(Object) method.
containsSingleValue in interface OneToManyMapvalue - The value being searched for.
true if any of the value sets contains a
matching value, otherwise returns falsepublic java.util.Set entrySet()
entrySet in interface java.util.Mappublic java.util.Set entries()
OneToManyMapjava.util.Map.entrySet()
method, however the entries returned map from a key to a value, rather
than from a key(K) to a value(V) rather than
froma key(K) to a set of values(Set<V>). java.util.Map.Entry.setValue(V).
entries in interface OneToManyMapSet<Entry<K, V>> representing all the key-value pairs in the ManyToOneMap.public java.util.Set get(java.lang.Object key)
get in interface java.util.Mappublic java.lang.Object getKey(java.lang.Object value)
OneToManyBiMapvalue. If the
specified value does not exist within the map then this method returns
null.
getKey in interface OneToManyBiMapvalue or null.public boolean isEmpty()
isEmpty in interface java.util.Mappublic java.util.Set keySet()
keySet in interface java.util.Map
public java.util.Set put(java.lang.Object key,
java.util.Set values)
put in interface java.util.Map
public java.lang.Object putSingleValue(java.lang.Object key,
java.lang.Object value)
OneToManyMapjava.util.Map.put(K, V)
, however it allows the user to add a single value to the map rather than
adding a java.util.Set containing one or more values. If the
specified key already has a set of values associated with it then the new
value is added to this set. Otherwise a new set is created and the new
value is added to that.
putSingleValue in interface OneToManyMappublic void putAll(java.util.Map m)
putAll in interface java.util.Mappublic void putAllSingleValues(java.util.Map m)
OneToManyMapjava.utilMap.putAll(Map m),
however the map specified is from keys to values instead of keys to sets
of values.
putAllSingleValues in interface OneToManyMapm - A map containing the key-value mappings to be added to the
ManyToOneMap.public java.util.Set remove(java.lang.Object key)
remove in interface java.util.Mappublic java.lang.Object removeValue(java.lang.Object value)
OneToManyBiMapvalue from the OneToManyBiMap. If this was the only value associated with the key to this value, then the key is also removed.
removeValue in interface OneToManyBiMapvalue - The value to be removed.
public int size()
size in interface java.util.Mappublic java.util.Collection values()
values in interface java.util.Mappublic java.util.Collection flatValues()
OneToManyMapvalues() the values are in a single flattened
Collection<V> rather than a
Collection<Set<V>>.
flatValues in interface OneToManyMap
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||