@Generated(date="2015-05-07T09:33:04+0200", value="KTypeVTypeMap.java") public interface IntByteMap extends IntByteAssociativeContainer
| Modifier and Type | Method and Description |
|---|---|
byte |
addTo(int key, byte additionValue)
An equivalent of calling
|
void |
clear()
Clear all keys and values in the container.
|
boolean |
equals(Object
Compares the specified object with this set for equality.
|
byte |
get(int key)
|
byte |
getOrDefault(int key, byte defaultValue)
|
int |
hashCode()
|
boolean |
indexExists(int index)
|
byte |
indexGet(int index)
Returns the value associated with an existing key.
|
void |
indexInsert(int index, int key, byte value)
Inserts a key-value pair for a key that is not present in the map.
|
int |
indexOf(int key)
Returns a logical "index" of a given key that can be used to speed up follow-up value setters or getters in certain scenarios (conditional logic).
|
byte |
indexReplace(int index, byte newValue)
Replaces the value associated with an existing key and returns any previous value stored for that key.
|
byte |
put(int key, byte value)
Place a given key and value in the container.
|
int |
putAll(IntByteAssociativeContainer
Puts all keys from another container to this map, replacing the values of existing keys, if such keys are present.
|
int |
putAll(Iterable
Puts all keys from an iterable cursor to this map, replacing the values of existing keys, if such keys are present.
|
byte |
putOrAdd(int key, byte putValue, byte incrementValue)
If
key exists,
putValue is inserted into the map, otherwise any existing value is incremented by
additionValue.
|
void |
release()
Removes all elements from the collection and additionally releases any internal buffers.
|
byte |
remove(int key)
Remove all values at the given key.
|
String |
visualizeKeyDistribution(int characters)
Visually depict the distribution of keys.
|
containsKey, forEach, forEach, isEmpty, iterator, keys, removeAll, removeAll, removeAll, size, valuesforEach, spliteratorbyte get(int key)
byte getOrDefault(int key,
byte defaultValue)
byte put(int key,
byte value)
int putAll(IntByteAssociativeContainercontainer)
int putAll(Iterable<? extends IntByteCursor > iterable)
byte putOrAdd(int key,
byte putValue,
byte incrementValue)
key exists,
putValue is inserted into the map, otherwise any existing value is incremented by
additionValue.
key - The key of the value to adjust.
putValue - The value to put if
key does not exist.
incrementValue - The value to add to the existing value if
key exists.
key (after changes).
byte addTo(int key,
byte additionValue)
putOrAdd(key, additionValue, additionValue);
key - The key of the value to adjust.
additionValue - The value to put or add to the existing value if
key exists.
key (after changes).
byte remove(int key)
boolean equals(Objectobj)
IntByteMap and both objects contains exactly the same key-value pairs.
int hashCode()
int indexOf(int key)
key - The key to locate in the map.
indexExists(int),
indexGet(int),
indexInsert(int, int, byte),
indexReplace(int, byte)
boolean indexExists(int index)
index - The index of a given key, as returned from
indexOf(int).
true if the index corresponds to an existing key or false otherwise. This is equivalent to checking whether the index is a positive value (existing keys) or a negative value (non-existing keys).
indexOf(int)
byte indexGet(int index)
index - The index of an existing key.
AssertionError - If assertions are enabled and the index does not correspond to an existing key.
indexOf(int)
byte indexReplace(int index,
byte newValue)
index - The index of an existing key.
AssertionError - If assertions are enabled and the index does not correspond to an existing key.
indexOf(int)
void indexInsert(int index,
int key,
byte value)
index - The index of a previously non-existing key, as returned from
indexOf(int).
AssertionError - If assertions are enabled and the index corresponds to an existing key.
indexOf(int)
void clear()
release()
void release()
clear() should be a better alternative since it'll avoid reallocation.
clear()
StringvisualizeKeyDistribution(int characters)
characters - The number of characters to "squeeze" the entire buffer into.