Package fr.andross.banitem.utils
Class DoubleMap<K,V>
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<K,V>
fr.andross.banitem.utils.DoubleMap<K,V>
- All Implemented Interfaces:
Serializable
,Cloneable
,Map<K,
V>
- Direct Known Subclasses:
CustomItems
,MetaItems
A simple double map, used to handle custom and meta items.
- Version:
- 3.1
- Author:
- Andross
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,
V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Constructor Summary
-
Method Summary
Methods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, putAll, putIfAbsent, remove, replace, replace, replaceAll, size, values
Methods inherited from class java.util.AbstractMap
equals, hashCode, toString
-
Constructor Details
-
DoubleMap
public DoubleMap()
-
-
Method Details
-
put
Adding in both maps -
clear
public void clear()Will clear the map and its reversed one -
remove
Remove the key from both maps -
getKey
Get the key of this value from the reversed map- Parameters:
value
- value- Returns:
- the key of this value if exists, otherwise null
-
getReversed
Get the reversed map- Returns:
- the reversed map
-