antlr.collections.impl
Class IndexedVector

java.lang.Object
  |
  +--antlr.collections.impl.IndexedVector

public class IndexedVector
extends Object

Untamed: A simple indexed vector: a normal vector except that you must specify a key when adding an element. This allows fast lookup and allows the order of specification to be preserved.


Field Summary
protected  Vector elements
           
protected  Hashtable index
           
 
Constructor Summary
IndexedVector()
          Enabled: IndexedVector constructor comment.
IndexedVector(int size)
          Enabled: IndexedVector constructor comment.
 
Method Summary
 void appendElement(Object key, Object value)
          Enabled:
 Object elementAt(int i)
          Enabled: Returns the element at the specified index.
 Enumeration elements()
          Enabled:
 Object getElement(Object key)
          Enabled:
 boolean removeElement(Object key)
          Enabled: remove element referred to by key NOT value; return false if not found.
 int size()
          Enabled:
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

elements

protected Vector elements

index

protected Hashtable index
Constructor Detail

IndexedVector

public IndexedVector()
Enabled: IndexedVector constructor comment.


IndexedVector

public IndexedVector(int size)
Enabled: IndexedVector constructor comment.

Parameters:
size - int
Method Detail

appendElement

public void appendElement(Object key,
                          Object value)
Enabled:


elementAt

public Object elementAt(int i)
Enabled: Returns the element at the specified index.


elements

public Enumeration elements()
Enabled:


getElement

public Object getElement(Object key)
Enabled:


removeElement

public boolean removeElement(Object key)
Enabled: remove element referred to by key NOT value; return false if not found.


size

public int size()
Enabled:



comments?