|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Provides a single interface for dealing with various flavors of double arrays. This arrays framework follows the model of the Collections API by allowing a user to select from a number of array implementations with support for various storage mechanisms such as automatic expansion, contraction, and array "rolling".
Method Summary | |
void |
addElement(double value)
Adds an element to the end of this expandable array |
double |
addElementRolling(double value)
Adds an element and moves the window of elements up one. |
void |
clear()
Clear the double array |
double |
getElement(int index)
Returns the element at the specified index. |
double[] |
getElements()
Returns a double[] of elements |
int |
getNumElements()
Returns the number of elements currently in the array. |
void |
setElement(int index,
double value)
Sets the element at the specified index. |
Method Detail |
public int getNumElements()
public double getElement(int index)
index
- index to fetch a value from
public void setElement(int index, double value)
index
- index to store a value invalue
- value to store at the specified indexpublic void addElement(double value)
value
- to be added to end of arraypublic double addElementRolling(double value)
value
- the value to be added to the array
public double[] getElements()
public void clear()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |