Class TwoDHashMap<K1,K2,V>
java.lang.Object
org.supercsv.util.TwoDHashMap<K1,K2,V>
- Type Parameters:
K1- the first key typeK2- the second key typeV- the value type
A two-dimensional hashmap, is a HashMap that enables you to refer to values via two keys rather than one. The
underlying implementation is simply a HashMap containing HashMap, each of which maps to values.
- Since:
- 2.0.0 (migrated from Spiffy 0.5)
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a new TwoDHashMap.Constructs a new TwoDHashMap using the supplied map. -
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsKey(K1 firstKey, K2 secondKey) Existence check of a value (or null) mapped to the keys.Fetch a value from the Hashmap .keySet()Returns a set of the keys of the outermost map.Insert a valueintsize()Returns the number of key-value mappings in this map for the first key.intReturns the number of key-value mappings in this map for the second key.
-
Field Details
-
map
-
-
Constructor Details
-
TwoDHashMap
public TwoDHashMap()Constructs a new TwoDHashMap. -
TwoDHashMap
-
-
Method Details
-
containsKey
-
get
-
set
-
size
public int size()Returns the number of key-value mappings in this map for the first key.- Returns:
- Returns the number of key-value mappings in this map for the first key.
-
size
Returns the number of key-value mappings in this map for the second key.- Parameters:
firstKey- the first key- Returns:
- Returns the number of key-value mappings in this map for the second key.
-
keySet
-