public class TwoDimensionalMap<K1,K2,V> extends Object implements Serializable, Iterable<TwoDimensionalMap.Entry<K1,K2,V>>
Modifier and Type | Class and Description |
---|---|
static class |
TwoDimensionalMap.Entry<K1,K2,V>
This inner class represents a single entry in the TwoDimensionalMap.
|
Constructor and Description |
---|
TwoDimensionalMap() |
TwoDimensionalMap(MapFactory<K1,Map<K2,V>> mf1,
MapFactory<K2,V> mf2) |
TwoDimensionalMap(TwoDimensionalMap<K1,K2,V> tdm) |
Modifier and Type | Method and Description |
---|---|
<V2> void |
addAll(TwoDimensionalMap<? extends K1,? extends K2,? extends V2> other,
java.util.function.Function<V2,V> function)
Adds all of the entries in the
other map, performing
function on them to transform the values |
void |
clear() |
boolean |
contains(K1 key1,
K2 key2) |
boolean |
containsKey(K1 key1) |
boolean |
equals(Object o) |
Set<K1> |
firstKeySet() |
Map<K2,V> |
get(K1 key1) |
V |
get(K1 key1,
K2 key2) |
Map<K2,V> |
getMap(K1 key1) |
int |
hashCode() |
static <K1,K2,V> TwoDimensionalMap<K1,K2,V> |
hashMap() |
static <K1,K2,V> TwoDimensionalMap<K1,K2,V> |
identityHashMap() |
boolean |
isEmpty() |
Iterator<TwoDimensionalMap.Entry<K1,K2,V>> |
iterator()
Iterate over the map using the iterator and entry inner classes.
|
void |
put(K1 key1) |
V |
put(K1 key1,
K2 key2,
V value) |
void |
remove(K1 key1)
Removes all of the data associated with the first key in the map
|
V |
remove(K1 key1,
K2 key2) |
Set<K2> |
secondKeySet() |
int |
size() |
String |
toString() |
static <K1,K2,V> TwoDimensionalMap<K1,K2,V> |
treeMap() |
Iterator<V> |
valueIterator() |
Collection<V> |
values() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, spliterator
public TwoDimensionalMap()
public TwoDimensionalMap(TwoDimensionalMap<K1,K2,V> tdm)
public TwoDimensionalMap(MapFactory<K1,Map<K2,V>> mf1, MapFactory<K2,V> mf2)
public int size()
public boolean isEmpty()
public void put(K1 key1)
public void remove(K1 key1)
public void clear()
public boolean containsKey(K1 key1)
public Collection<V> values()
public <V2> void addAll(TwoDimensionalMap<? extends K1,? extends K2,? extends V2> other, java.util.function.Function<V2,V> function)
other
map, performing
function
on them to transform the valuespublic static <K1,K2,V> TwoDimensionalMap<K1,K2,V> hashMap()
public static <K1,K2,V> TwoDimensionalMap<K1,K2,V> treeMap()
public static <K1,K2,V> TwoDimensionalMap<K1,K2,V> identityHashMap()
public Iterator<TwoDimensionalMap.Entry<K1,K2,V>> iterator()