| Constructor and Description |
|---|
MultiKeysMap() |
| Modifier and Type | Method and Description |
|---|---|
void |
clean()
Removes all mapping from this maps
|
Set<V> |
getValuesByPrimaryKey(K1 key)
Returns the values to which this map maps the specified primary key
|
Set<V> |
getValuesBySecondaryKey(K2 key)
Returns the values to which this map maps the specified primary key
|
Iterator<V> |
iterator() |
Set<K1> |
primaryKeySet()
Returns a set view of the primary keys contained in this map
|
void |
put(K1 key1,
K2 key2,
V value)
Associates the specified value with the two keys
|
void |
removeValue(V value)
removes the given values and its keys from the map
|
void |
removeValuesByPrimaryKey(K1 key)
Removes all the values associated to the primary key
|
void |
removeValuesBySecondaryKey(K2 key)
Removes all the values associated to the secondary key
|
Set<K2> |
secondaryKeySet()
Returns a set view of the secondary keys contained in this map
|
Collection<V> |
values()
Returns a collection view of the values contained in this map
|
public void put(K1 key1, K2 key2, V value)
key1 - the value's primary keykey2 - the value's secondary keyvalue - the valuepublic void removeValue(V value)
value - public void removeValuesByPrimaryKey(K1 key)
key - the key of type K1public void removeValuesBySecondaryKey(K2 key)
key - the key of type K2public Set<V> getValuesByPrimaryKey(K1 key)
key - key whose associated values are to be returnedpublic Set<V> getValuesBySecondaryKey(K2 key)
key - key whose associated values are to be returnedpublic Set<K1> primaryKeySet()
public Set<K2> secondaryKeySet()
public Collection<V> values()
public void clean()
Copyright © 2015. All Rights Reserved.