public final class HashLongMapV6 extends java.lang.Object implements HashLongMap, java.lang.Cloneable
HashLongMap.State
Modifier and Type | Field and Description |
---|---|
static int |
SIZE_OF
MEMORY USAGE: The number of bytes for one instance of a HashLongMap
|
Constructor and Description |
---|
HashLongMapV6()
Constructs a new, empty map with a default capacity and load
factor, which is 0.75.
|
HashLongMapV6(int initialCapacity)
Constructs a new, empty map with the specified initial capacity
and default load factor, which is 0.75.
|
Modifier and Type | Method and Description |
---|---|
long[] |
briefKeyArray()
create an array of the first 200 odd keys
|
void |
clear()
Removes all mappings from this map.
|
java.lang.Object |
clone()
clone the memory handler group.
|
boolean |
containsKey(long key)
Returns true if this map contains a mapping for the specified
key.
|
boolean |
containsValue(java.lang.Object value)
Returns true if this map maps one or more keys to the
specified value.
|
java.lang.Object |
get(long key)
Returns the value to which this map maps the specified key.
|
long[] |
getKeyArray()
create an array of the keys
|
long[][] |
getKeyData()
create an array of arrays for the keys.
|
long[] |
getSortedKeyArray()
create an array of the keys
SORTED array.
|
boolean |
isEmpty()
Returns true if this map contains no key-value mappings.
|
boolean |
isInitialized()
is this hash map initialized.
|
boolean |
isKeyArraySorted()
Is the key array sorted ?
|
java.lang.Object |
put(long key,
java.lang.Object value)
Associates the specified value with the specified key in this map.
|
void |
putMultiRows(long[] rows,
java.lang.Object value,
HashLongMap.State stateOfRows)
put multiple rows.
|
java.lang.Object |
remove(long key)
Removes the mapping for this key from this map if present.
|
int |
size()
Returns the number of key-value mappings in this map.
|
long |
sizeOf()
calculate the estimated size in bytes
|
public static final int SIZE_OF
public HashLongMapV6(int initialCapacity)
initialCapacity
- the initial capacity of the HashMap.public HashLongMapV6()
public boolean isInitialized()
isInitialized
in interface HashLongMap
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in interface HashLongMap
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
- doesn't happen.public int size()
size
in interface HashLongMap
public boolean isEmpty()
isEmpty
in interface HashLongMap
public boolean containsValue(java.lang.Object value)
containsValue
in interface HashLongMap
value
- value whose presence in this map is to be tested.public long[] briefKeyArray()
briefKeyArray
in interface HashLongMap
public long[] getKeyArray()
getKeyArray
in interface HashLongMap
public boolean isKeyArraySorted()
isKeyArraySorted
in interface HashLongMap
public long[] getSortedKeyArray()
getSortedKeyArray
in interface HashLongMap
public boolean containsKey(long key)
containsKey
in interface HashLongMap
key
- key whose presence in this Map is to be tested.public java.lang.Object get(long key)
get
in interface HashLongMap
key
- key whose associated value is to be returned.public java.lang.Object put(long key, java.lang.Object value)
put
in interface HashLongMap
value
- The object to place into the table.key
- key with which the specified value is to be associated.public void putMultiRows(long[] rows, java.lang.Object value, HashLongMap.State stateOfRows)
putMultiRows
in interface HashLongMap
rows
- the rowsvalue
- the valuestateOfRows
- are these rows known to be sorted ?public java.lang.Object remove(long key)
remove
in interface HashLongMap
key
- key whose mapping is to be removed from the map.public void clear()
clear
in interface HashLongMap
public long sizeOf()
sizeOf
in interface HashLongMap
sizeOf
in interface InterfaceSizeOf
public long[][] getKeyData()
HashLongMap
getKeyData
in interface HashLongMap
stSoftware Copyright © 2001-2014 stSoftware All Rights Reserved.