ARRAYTYPE
- Primitive a type of the backing arraypublic abstract class ArrayFeatureVector<ARRAYTYPE> extends Object implements FeatureVector
FeatureVector
that are backed by
a native array.Modifier and Type | Field and Description |
---|---|
ARRAYTYPE |
values
Array of all the values in the feature vector
|
Constructor and Description |
---|
ArrayFeatureVector() |
Modifier and Type | Method and Description |
---|---|
ARRAYTYPE |
getVector()
Get the underlying representation
|
abstract ArrayFeatureVector<ARRAYTYPE> |
subvector(int beginIndex)
Returns a new featurevector that is a subsequence of this vector.
|
abstract ArrayFeatureVector<ARRAYTYPE> |
subvector(int beginIndex,
int endIndex)
Returns a new string that is a subvector of this vector.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
asDoubleFV, asDoubleVector, getAsDouble, length, newInstance, normaliseFV, normaliseFV, normaliseFV, normaliseFV, setFromDouble
asciiHeader, readASCII
binaryHeader, readBinary
asciiHeader, writeASCII
binaryHeader, writeBinary
public ArrayFeatureVector()
public ARRAYTYPE getVector()
getVector
in interface FeatureVector
public abstract ArrayFeatureVector<ARRAYTYPE> subvector(int beginIndex)
beginIndex
- the beginning index, inclusive.IndexOutOfBoundsException
- if beginIndex
is negative or larger than the
length of this ArrayFeatureVector
object.public abstract ArrayFeatureVector<ARRAYTYPE> subvector(int beginIndex, int endIndex)
beginIndex
and extends to the
element at index endIndex - 1
. Thus the length of the
subvector is endIndex-beginIndex
.beginIndex
- the beginning index, inclusive.endIndex
- the ending index, exclusive.IndexOutOfBoundsException
- if the beginIndex
is negative, or
endIndex
is larger than the length of this
ArrayFeatureVector
object, or
beginIndex
is larger than
endIndex
.