org.exist.util.hashtable
Class SequencedLongHashMap

java.lang.Object
  extended byorg.exist.util.hashtable.AbstractHashtable
      extended byorg.exist.util.hashtable.SequencedLongHashMap

public class SequencedLongHashMap
extends AbstractHashtable


Nested Class Summary
static class SequencedLongHashMap.Entry
          Represents an entry in the map.
protected  class SequencedLongHashMap.SequencedLongIterator
           
 
Nested classes inherited from class org.exist.util.hashtable.AbstractHashtable
AbstractHashtable.HashtableIterator, AbstractHashtable.HashtableOverflowException
 
Field Summary
protected  long[] keys
           
protected  SequencedLongHashMap.Entry[] values
           
 
Fields inherited from class org.exist.util.hashtable.AbstractHashtable
items, maxRehash, REMOVED, tabSize
 
Constructor Summary
SequencedLongHashMap()
           
SequencedLongHashMap(int iSize)
           
 
Method Summary
 void clear()
          Clear the map.
 java.lang.Object get(long key)
          Returns the value for key or null if the key is not in the map.
 SequencedLongHashMap.Entry getFirstEntry()
          Returns the first entry added to the map.
protected static int hash(long l)
           
protected  SequencedLongHashMap.Entry insert(long key, java.lang.Object value)
           
 java.util.Iterator iterator()
          Returns an iterator over all keys in the order in which they were inserted.
 void put(long key, java.lang.Object value)
          Add a new entry for the key.
 java.lang.Object remove(long key)
          Remove the entry specified by key from the map.
 void removeEntry(SequencedLongHashMap.Entry entry)
          Remove an entry.
 java.lang.Object removeFirst()
          Remove the first entry added to the map.
 java.util.Iterator valueIterator()
          Returns an iterator over all values in the order in which they were inserted.
 
Methods inherited from class org.exist.util.hashtable.AbstractHashtable
getMaxRehash, isPrime, nextPrime, size
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

keys

protected long[] keys

values

protected SequencedLongHashMap.Entry[] values
Constructor Detail

SequencedLongHashMap

public SequencedLongHashMap()

SequencedLongHashMap

public SequencedLongHashMap(int iSize)
Method Detail

put

public void put(long key,
                java.lang.Object value)
Add a new entry for the key.

Parameters:
key -
value -

insert

protected SequencedLongHashMap.Entry insert(long key,
                                            java.lang.Object value)

get

public java.lang.Object get(long key)
Returns the value for key or null if the key is not in the map.

Parameters:
key -
Returns:

getFirstEntry

public SequencedLongHashMap.Entry getFirstEntry()
Returns the first entry added to the map.

Returns:

remove

public java.lang.Object remove(long key)
Remove the entry specified by key from the map.

Parameters:
key -
Returns:

removeFirst

public java.lang.Object removeFirst()
Remove the first entry added to the map.

Returns:

removeEntry

public void removeEntry(SequencedLongHashMap.Entry entry)
Remove an entry.

Parameters:
entry -

clear

public void clear()
Clear the map.


hash

protected static final int hash(long l)

iterator

public java.util.Iterator iterator()
Returns an iterator over all keys in the order in which they were inserted.

Specified by:
iterator in class AbstractHashtable

valueIterator

public java.util.Iterator valueIterator()
Returns an iterator over all values in the order in which they were inserted.

Specified by:
valueIterator in class AbstractHashtable


<oXygen/> XML Editor provides support for editing and debugging XQuery expressions against the eXist XML Database.