Class FloatArrayVector
java.lang.Object
opennlp.tools.util.wordvector.FloatArrayVector
- All Implemented Interfaces:
WordVector
A
WordVector implementation that represents the vector as array
of float values.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
vector
private final float[] vector
-
-
Constructor Details
-
FloatArrayVector
FloatArrayVector(float[] vector)
-
-
Method Details
-
getDataType
- Specified by:
getDataTypein interfaceWordVector
-
getAsFloat
public float getAsFloat(int index) - Specified by:
getAsFloatin interfaceWordVector
-
getAsDouble
public double getAsDouble(int index) - Specified by:
getAsDoublein interfaceWordVector
-
toFloatBuffer
- Specified by:
toFloatBufferin interfaceWordVector
-
toDoubleBuffer
- Specified by:
toDoubleBufferin interfaceWordVector
-
dimension
public int dimension()- Specified by:
dimensionin interfaceWordVector
-