All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.bulletproof.util.IntVector

java.lang.Object
   |
   +----com.bulletproof.util.IntVector

public class IntVector
extends Object
A simple expandable vector of integers, similar to java.util.Vector.


Constructor Index

 o IntVector(int)
Create a new IntVector.

Method Index

 o append(int)
Append an integer to the end, expanding the vector if necessary.
 o removeAllElements()
Mark the vector as containing no integers.
 o setValueAt(int, int)
What is the value at a given index? N.B.
 o size()
What is the size of this IntVector?
 o valueAt(int)
What is the value at a given index? N.B.

Constructors

 o IntVector
 public IntVector(int initSize)
Create a new IntVector.

Parameters:
initSize - the number of initial elements to allocate

Methods

 o valueAt
 public int valueAt(int i)
What is the value at a given index? N.B. This does no bounds checking.

Parameters:
i - the index of the entry
Returns:
the integer at that index.
 o size
 public int size()
What is the size of this IntVector?

Returns:
the number of integers stored
 o append
 public void append(int i)
Append an integer to the end, expanding the vector if necessary.

Parameters:
i - the value of the new datum
 o setValueAt
 public void setValueAt(int i,
                        int value)
What is the value at a given index? N.B. This does no bounds checking.

Parameters:
i - the index of the entry
the - new value for this index.
 o removeAllElements
 public void removeAllElements()
Mark the vector as containing no integers.


All Packages  Class Hierarchy  This Package  Previous  Next  Index