public final class ObjectIntMap extends Object
| 构造器和说明 |
|---|
ObjectIntMap()
Equivalent to
IntObjectMap(11, 0.75F). |
ObjectIntMap(int initialCapacity)
Equivalent to
IntObjectMap(capacity, 0.75F). |
ObjectIntMap(int initialCapacity,
float loadFactor)
Constructs an IntObjectMap with specified initial capacity and load factor.
|
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
contains(Object key) |
boolean |
get(Object key,
int[] out)
Returns the value that is mapped to a given 'key'.
|
Object[] |
keys() |
void |
put(Object key,
int value)
Updates the table to map 'key' to 'value'.
|
void |
remove(Object key)
Updates the table to map 'key' to 'value'.
|
int |
size()
Returns the number of key-value mappings in this map.
|
String |
toString()
Overrides Object.toString() for debug purposes.
|
public ObjectIntMap()
IntObjectMap(11, 0.75F).public ObjectIntMap(int initialCapacity)
IntObjectMap(capacity, 0.75F).public ObjectIntMap(int initialCapacity,
float loadFactor)
initialCapacity - initial number of hash buckets in the table [may not be negative, 0 is equivalent to 1].loadFactor - the load factor to use to determine rehashing points [must be in (0.0, 1.0] range].public String toString()
public int size()
public boolean contains(Object key)
public boolean get(Object key, int[] out)
key - mapping key [may not be null]out - holder for the found value [must be at least of size 1]public Object[] keys()
public void put(Object key, int value)
key - mapping key [may not be null]value - mapping value.public void remove(Object key)
key - mapping key [may not be null]Copyright © 2018. All rights reserved.