|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnz.ac.waikato.mcennis.rat.reusablecores.datavector.DoubleArrayDataVector
public class DoubleArrayDataVector
Class cretaing a data vector backed by a double array.
| Constructor Summary | |
|---|---|
DoubleArrayDataVector(double[] source)
Create a data vector from the given double array. |
|
| Method Summary | |
|---|---|
int |
compareTo(java.lang.Object o)
|
java.lang.Comparable |
getCurrentIndex()
return the index at the current position of the iterator |
double |
getCurrentValue()
return the value at the current position of the iterator. |
double |
getValue(java.lang.Comparable index)
Get the value at the given index. |
boolean |
hasNext()
Does the vector contain any additional non-zero values? |
void |
next()
Move the iterator to the next non-zero index-value pair |
void |
reset()
Reset the iterator to the first index of the function, potentially creating a new ordering of objects on some data vectors (i.e. |
void |
setSize(int s)
Set the dimensionality of this vector |
int |
size()
Returns the number of dimensions of this object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DoubleArrayDataVector(double[] source)
source - source data array| Method Detail |
|---|
public int size()
DataVector
size in interface DataVectorpublic void setSize(int s)
DataVector
setSize in interface DataVectors - dimensionality of the vectorpublic double getValue(java.lang.Comparable index)
DataVector
getValue in interface DataVectorindex - index of the desired value
public void reset()
DataVector
reset in interface DataVectorpublic double getCurrentValue()
DataVector
getCurrentValue in interface DataVectorpublic java.lang.Comparable getCurrentIndex()
DataVector
getCurrentIndex in interface DataVectorpublic void next()
DataVector
next in interface DataVectorpublic boolean hasNext()
DataVector
hasNext in interface DataVectorpublic int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparable
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||