Package com.comphenix.protocol.wrappers
Class WrappedIntHashMap
java.lang.Object
com.comphenix.protocol.wrappers.AbstractWrapper
com.comphenix.protocol.wrappers.WrappedIntHashMap
Deprecated.
IntHashMap no longer exists
Represents a wrapper for the internal IntHashMap in Minecraft.
-
Field Summary
Fields inherited from class com.comphenix.protocol.wrappers.AbstractWrapper
handle, handleType -
Method Summary
Modifier and TypeMethodDescriptionstatic WrappedIntHashMapfromHandle(Object handle) Deprecated.Construct a wrapper around a given NMS IntHashMap.get(int key) Deprecated.Retrieve the value associated with a specific key, or NULL if not found.static WrappedIntHashMapnewMap()Deprecated.Construct a new IntHashMap.voidDeprecated.Associates a specified key with the given value in the integer map.remove(int key) Deprecated.Remove a mapping of a key to a value if it is present.Methods inherited from class com.comphenix.protocol.wrappers.AbstractWrapper
equals, getHandle, getHandleType, hashCode, setHandle, toString
-
Method Details
-
newMap
Deprecated.Construct a new IntHashMap.- Returns:
- A new IntHashMap.
-
fromHandle
Deprecated.Construct a wrapper around a given NMS IntHashMap.- Parameters:
handle- - the NMS IntHashMap.- Returns:
- The created wrapped.
- Throws:
IllegalArgumentException- If the handle is not an IntHasMap.
-
put
Deprecated.Associates a specified key with the given value in the integer map.If the key has already been associated with a value, then it will be replaced by the new value.
- Parameters:
key- - the key to insert.value- - the value to insert. Cannot be NULL.- Throws:
RuntimeException- If the reflection machinery failed.
-
get
Deprecated.Retrieve the value associated with a specific key, or NULL if not found.- Parameters:
key- - the integer key.- Returns:
- The associated value, or NULL.
-
remove
Deprecated.Remove a mapping of a key to a value if it is present.- Parameters:
key- - the key of the mapping to remove.- Returns:
- The object that was removed, or NULL if the key is not present.
-