U
- Unitpublic static class MutableFloatVector.Rel<U extends Unit<U>> extends AbstractMutableFloatVectorRel<U,FloatVector.Rel<U>,MutableFloatVector.Rel<U>,FloatScalar.Rel<U>>
AbstractFloatVectorRel.Itr
data
Constructor and Description |
---|
Rel(float[] values,
U unit,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Rel(FloatScalar.Rel<U>[] values,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Rel(FloatVectorData data,
U unit)
Construct a new Relative Mutable FloatVector.
|
Rel(List<Float> values,
U unit,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Rel(List<FloatScalar.Rel<U>> values,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Rel(SortedMap<Integer,Float> values,
U unit,
int length,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Rel(SortedMap<Integer,FloatScalar.Rel<U>> values,
int length,
StorageType storageType)
Construct a new Relative Mutable FloatVector.
|
Modifier and Type | Method and Description |
---|---|
protected MutableFloatVector.Rel<U> |
instantiateMutableType(FloatVectorData dvd,
U unit)
Construct a new Relative Mutable FloatVector of the right type.
|
protected FloatScalar.Rel<U> |
instantiateScalar(float value,
U unit)
Construct a new Relative Immutable FloatScalar of the right type.
|
protected FloatVector.Rel<U> |
instantiateType(FloatVectorData dvd,
U unit)
Construct a new Relative Immutable FloatVector of the right type.
|
MutableFloatVector.Rel<U> |
toDense()
return a dense version of this vector.
|
MutableFloatVector.Rel<U> |
toSparse()
return a sparse version of this vector.
|
abs, assign, ceil, checkCopyOnWrite, copy, decrementBy, decrementBy, decrementBy, divideBy, divideBy, divideBy, floor, immutable, incrementBy, incrementBy, incrementBy, multiplyBy, multiplyBy, multiplyBy, mutable, neg, normalize, rint, round, set, setCopyOnWrite, setInUnit, setSI
checkUnit, checkUnit, checkUnit, divide, get, iterator, minus, plus, times
cardinality, checkIndex, checkSize, checkSize, equals, getData, getInUnit, getInUnit, getSI, getStorageType, getValuesInUnit, getValuesInUnit, getValuesSI, hashCode, size, toString, toString, toString, toString, zSum
expressAsSIUnit, expressAsSpecifiedUnit, getUnit, isAbsolute, isRelative, setDisplayUnit
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
DIV, MULT, POW
cardinality, getInUnit, getInUnit, getSI, getValuesInUnit, getValuesInUnit, getValuesSI, size, toString, toString, toString, toString, zSum
forEach, spliterator
public Rel(float[] values, U unit, StorageType storageType) throws ValueException
values
- float[]; the values of the entries in the new Relative Mutable FloatVectorunit
- U; the unit of the new Relative Mutable FloatVectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values is nullpublic Rel(List<Float> values, U unit, StorageType storageType) throws ValueException
values
- List<Float>; the values of the entries in the new Relative Mutable FloatVectorunit
- U; the unit of the new Relative Mutable FloatVectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values is nullpublic Rel(FloatScalar.Rel<U>[] values, StorageType storageType) throws ValueException
values
- FloatScalar.Rel<U>[]; the values of the entries in the new Relative Mutable FloatVectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values has zero entriespublic Rel(List<FloatScalar.Rel<U>> values, StorageType storageType) throws ValueException
values
- List<FloatScalar.Rel<U>>; the values of the entries in the new Relative Mutable FloatVectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values has zero entriespublic Rel(SortedMap<Integer,FloatScalar.Rel<U>> values, int length, StorageType storageType) throws ValueException
values
- SortedMap<Integer, FloatScalar.Rel<U>>; the values of the entries in the new Relative
Sparse Mutable FloatVectorlength
- int; the size of the vectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values has zero entriespublic Rel(SortedMap<Integer,Float> values, U unit, int length, StorageType storageType) throws ValueException
values
- SortedMap<Integer, Float>; the map of indexes to values of the Relative Sparse Mutable
FloatVectorunit
- U; the unit of the new Relative Sparse Mutable FloatVectorlength
- int; the size of the vectorstorageType
- StorageType; the data type to use (e.g., DENSE or SPARSE)ValueException
- when values is nullpublic Rel(FloatVectorData data, U unit)
data
- FloatVectorData; an internal data objectunit
- U; the unitprotected final FloatVector.Rel<U> instantiateType(FloatVectorData dvd, U unit)
instantiateType
in class AbstractFloatVectorRel<U extends Unit<U>,FloatVector.Rel<U extends Unit<U>>,MutableFloatVector.Rel<U extends Unit<U>>,FloatScalar.Rel<U extends Unit<U>>>
dvd
- FloatVectorData; an internal data objectunit
- U; the unitprotected final MutableFloatVector.Rel<U> instantiateMutableType(FloatVectorData dvd, U unit)
instantiateMutableType
in class AbstractFloatVectorRel<U extends Unit<U>,FloatVector.Rel<U extends Unit<U>>,MutableFloatVector.Rel<U extends Unit<U>>,FloatScalar.Rel<U extends Unit<U>>>
dvd
- FloatVectorData; an internal data objectunit
- U; the unitprotected final FloatScalar.Rel<U> instantiateScalar(float value, U unit)
instantiateScalar
in class AbstractFloatVectorRel<U extends Unit<U>,FloatVector.Rel<U extends Unit<U>>,MutableFloatVector.Rel<U extends Unit<U>>,FloatScalar.Rel<U extends Unit<U>>>
value
- float; the valueunit
- U; the unitpublic final MutableFloatVector.Rel<U> toDense()
public final MutableFloatVector.Rel<U> toSparse()
Copyright © 2015–2019 Delft University of Technology. All rights reserved.