Package com.viaversion.viaversion.util
Class Int2IntBiHashMap
java.lang.Object
com.viaversion.viaversion.util.Int2IntBiHashMap
- All Implemented Interfaces:
Int2IntBiMap
,it.unimi.dsi.fastutil.Function<Integer,
,Integer> it.unimi.dsi.fastutil.ints.Int2IntFunction
,it.unimi.dsi.fastutil.ints.Int2IntMap
,Function<Integer,
,Integer> IntUnaryOperator
,Map<Integer,
Integer>
-
Nested Class Summary
Nested classes/interfaces inherited from interface it.unimi.dsi.fastutil.ints.Int2IntMap
it.unimi.dsi.fastutil.ints.Int2IntMap.Entry, it.unimi.dsi.fastutil.ints.Int2IntMap.FastEntrySet
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
boolean
containsKey
(int key) boolean
containsValue
(int value) int
void
defaultReturnValue
(int rv) int
get
(int key) it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.ints.Int2IntMap.Entry>
inverse()
Returns the inverse of this bimap.boolean
isEmpty()
@NonNull it.unimi.dsi.fastutil.ints.IntSet
keySet()
int
put
(int key, int value) Puts the key and value into the maps.void
boolean
remove
(int key, int value) int
size()
@NonNull it.unimi.dsi.fastutil.ints.IntSet
values()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface it.unimi.dsi.fastutil.Function
apply
Methods inherited from interface it.unimi.dsi.fastutil.ints.Int2IntFunction
andThen, andThenByte, andThenChar, andThenDouble, andThenFloat, andThenInt, andThenLong, andThenObject, andThenReference, andThenShort, applyAsInt, compose, composeByte, composeChar, composeDouble, composeFloat, composeInt, composeLong, composeObject, composeReference, composeShort, remove
Methods inherited from interface it.unimi.dsi.fastutil.ints.Int2IntMap
compute, compute, computeIfAbsent, computeIfAbsent, computeIfAbsent, computeIfAbsentNullable, computeIfAbsentPartial, computeIfPresent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, getOrDefault, merge, merge, mergeInt, mergeInt, put, putIfAbsent, putIfAbsent, remove, remove, replace, replace, replace, replace
Methods inherited from interface java.util.function.IntUnaryOperator
andThen, compose
Methods inherited from interface java.util.Map
equals, hashCode, replaceAll
-
Constructor Details
-
Int2IntBiHashMap
public Int2IntBiHashMap() -
Int2IntBiHashMap
public Int2IntBiHashMap(int expected)
-
-
Method Details
-
inverse
Description copied from interface:Int2IntBiMap
Returns the inverse of this bimap.- Specified by:
inverse
in interfaceInt2IntBiMap
- Returns:
- the inverse of this bimap
-
put
public int put(int key, int value) Description copied from interface:Int2IntBiMap
Puts the key and value into the maps.- Specified by:
put
in interfaceInt2IntBiMap
- Specified by:
put
in interfaceit.unimi.dsi.fastutil.ints.Int2IntFunction
- Parameters:
key
- keyvalue
- value- Returns:
- old value if present
-
remove
public boolean remove(int key, int value) - Specified by:
remove
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-
get
public int get(int key) - Specified by:
get
in interfaceit.unimi.dsi.fastutil.ints.Int2IntFunction
-
clear
public void clear() -
size
public int size() -
isEmpty
public boolean isEmpty() -
putAll
-
defaultReturnValue
public void defaultReturnValue(int rv) - Specified by:
defaultReturnValue
in interfaceit.unimi.dsi.fastutil.ints.Int2IntFunction
- Specified by:
defaultReturnValue
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-
defaultReturnValue
public int defaultReturnValue()- Specified by:
defaultReturnValue
in interfaceit.unimi.dsi.fastutil.ints.Int2IntFunction
- Specified by:
defaultReturnValue
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-
int2IntEntrySet
public it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.ints.Int2IntMap.Entry> int2IntEntrySet()- Specified by:
int2IntEntrySet
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-
keySet
public @NonNull it.unimi.dsi.fastutil.ints.IntSet keySet() -
values
public @NonNull it.unimi.dsi.fastutil.ints.IntSet values() -
containsKey
public boolean containsKey(int key) - Specified by:
containsKey
in interfaceit.unimi.dsi.fastutil.ints.Int2IntFunction
- Specified by:
containsKey
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-
containsValue
public boolean containsValue(int value) - Specified by:
containsValue
in interfaceit.unimi.dsi.fastutil.ints.Int2IntMap
-