
V - the concrete type of this AbstractNumberVectorN - the type of number, this AbstractNumberVector consists of (i.e., a
AbstractNumberVector v of type V and dimensionality
d is an element of Nd)public abstract class AbstractNumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number> extends Object implements NumberVector<V,N>
| Modifier and Type | Field and Description |
|---|---|
static String |
ATTRIBUTE_SEPARATOR
The String to separate attribute values in a String that represents the
values.
|
| Constructor and Description |
|---|
AbstractNumberVector() |
| Modifier and Type | Method and Description |
|---|---|
byte |
byteValue(int dimension)
Returns the value in the specified dimension as byte.
|
boolean |
equals(Object obj)
An Object obj is equal to this AbstractNumberVector if it is an instance of
the same runtime class and is of the identical dimensionality and the
values of this AbstractNumberVector are equal to the values of obj in all
dimensions, respectively.
|
float |
floatValue(int dimension)
Returns the value in the specified dimension as float.
|
double |
getMax(int dimension)
Returns the maximum coordinate at the specified dimension.
|
double |
getMin(int dimension)
Returns the minimum coordinate at the specified dimension.
|
int |
hashCode() |
int |
intValue(int dimension)
Returns the value in the specified dimension as int.
|
V |
newNumberVector(double[] values)
Returns a new NumberVector of N for the given values.
|
short |
shortValue(int dimension)
Returns the value in the specified dimension as short.
|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitdoubleValue, getColumnVector, longValue, newNumberVectorgetDimensionality, getValue, newFeatureVector, toStringgetDimensionalitypublic static final String ATTRIBUTE_SEPARATOR
public boolean equals(Object obj)
public double getMin(int dimension)
SpatialComparablegetMin in interface SpatialComparabledimension - the dimension for which the coordinate should be returned,
where 1 ≤ dimension ≤ getDimensionality()public double getMax(int dimension)
SpatialComparablegetMax in interface SpatialComparabledimension - the dimension for which the coordinate should be returned,
where 1 ≤ dimension ≤ getDimensionality()public byte byteValue(int dimension)
NumberVectorgetValue(dim).byteValue(), but usually this is much more efficient
due to boxing/unboxing cost.byteValue in interface NumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number>dimension - the desired dimension, where 1 ≤ dimension ≤
this.getDimensionality()public float floatValue(int dimension)
NumberVectorgetValue(dim).floatValue(), but usually this is much more efficient
due to boxing/unboxing cost.floatValue in interface NumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number>dimension - the desired dimension, where 1 ≤ dimension ≤
this.getDimensionality()public int intValue(int dimension)
NumberVectorgetValue(dim).intValue(), but usually this is much more efficient
due to boxing/unboxing cost.intValue in interface NumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number>dimension - the desired dimension, where 1 ≤ dimension ≤
this.getDimensionality()public short shortValue(int dimension)
NumberVectorgetValue(dim).shortValue(), but usually this is much more efficient
due to boxing/unboxing cost.shortValue in interface NumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number>dimension - the desired dimension, where 1 ≤ dimension ≤
this.getDimensionality()public V newNumberVector(double[] values)
NumberVectornewNumberVector in interface NumberVector<V extends AbstractNumberVector<? extends V,N>,N extends Number>values - the values of the NumberVector