Class OrderedLongKeyHashMap<V>
java.lang.Object
org.hsqldb.lib.OrderedLongKeyHashMap<V>
A Map of long primitives to Object values which maintains the insertion order
of the key/value pairs and allows access by index. Iterators return the keys
or values in the index order.
- Since:
- 1.9.0
- Author:
- Fred Toussi (fredt@users dot sourceforge.net)
-
Nested Class Summary
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionOrderedLongKeyHashMap(int initialCapacity) OrderedLongKeyHashMap(int initialCapacity, boolean hasAdditionalValues) -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clear the map completely.org.hsqldb.map.BaseHashMapclone()booleancontainsKey(long key) booleancontainsKey(Object key) booleancontainsValue(Object value) entrySet()get(long key) getFourthValueAt(int index) intgetIndex(long key) longgetKeyAt(int index) intgetLookup(long key) getSecondValueAt(int index) getThirdValueAt(int index) getValueAt(int index) booleanbooleanisEmpty()keySet()long[]keysToArray(long[] array) voidputAll(LongKeyHashMap<V> other) remove(long key) voidremoveEntry(int index) booleansetFourthValueAt(int index, Object value) booleansetKeyAt(int index, long key) setSecondValueAt(int index, Object value) setThirdValueAt(int index, Object value) setValueAt(int index, V value) intsize()values()Object[]<T> T[]valuesToArray(T[] array)
-
Field Details
-
ACCESS_MAX
public static final int ACCESS_MAX- See Also:
-
emptyObjectArray
-
-
Constructor Details
-
OrderedLongKeyHashMap
public OrderedLongKeyHashMap() -
OrderedLongKeyHashMap
- Throws:
IllegalArgumentException
-
OrderedLongKeyHashMap
public OrderedLongKeyHashMap(int initialCapacity, boolean hasAdditionalValues) throws IllegalArgumentException - Throws:
IllegalArgumentException
-
-
Method Details
-
containsKey
- Specified by:
containsKeyin interfaceMap<Long,V>
-
containsKey
public boolean containsKey(long key) -
containsValue
- Specified by:
containsValuein interfaceMap<Long,V>
-
get
-
get
-
getKeyAt
public long getKeyAt(int index) -
getValueAt
-
getSecondValueAt
-
getThirdValueAt
-
getFourthValueAt
-
setValueAt
-
setSecondValueAt
-
setThirdValueAt
-
setFourthValueAt
-
insert
- Throws:
IndexOutOfBoundsException
-
set
- Throws:
IndexOutOfBoundsException
-
setKeyAt
- Throws:
IndexOutOfBoundsException
-
getIndex
public int getIndex(long key) -
put
-
put
-
remove
-
remove
-
removeEntry
- Throws:
IndexOutOfBoundsException
-
getLookup
public int getLookup(long key) -
putAll
-
keysToArray
public long[] keysToArray(long[] array) -
valuesToArray
-
valuesToArray
public <T> T[] valuesToArray(T[] array) -
keySet
-
values
-
entrySet
-
clear
public void clear()Clear the map completely. -
size
public int size() -
isEmpty
public boolean isEmpty() -
clone
public org.hsqldb.map.BaseHashMap clone()
-