Package org.apache.sis.math
Class ArrayVector.UnsignedLongs
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<Number>
org.apache.sis.math.Vector
org.apache.sis.math.ArrayVector<Long>
org.apache.sis.math.ArrayVector.Longs
org.apache.sis.math.ArrayVector.UnsignedLongs
- All Implemented Interfaces:
Serializable,Iterable<Number>,Collection<Number>,List<Number>,RandomAccess,CheckedContainer<Long>
- Enclosing class:
- ArrayVector<E extends Number>
A vector backed by an array of type
long[] to be interpreted as unsigned values.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.sis.math.ArrayVector
ArrayVector.Decimal, ArrayVector.Doubles -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final longFor cross-version compatibility.Fields inherited from class java.util.AbstractList
modCount -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubledoubleValue(int index) Returns the unsigned long as adoublevalue.floatfloatValue(int index) Returns the unsigned long as afloatvalue.booleanDeclares this vector as unsigned.longlongValue(int index) Returns the unsigned long as alongvalue, if possible.(package private) NumberRange<Double>range(IntSupplier indices, int n) Finds the minimum and maximum values in the array or in a subset of the array.stringValue(int index) Returns the string representation at the given index.Methods inherited from class org.apache.sis.math.ArrayVector.Longs
buffer, equals, fill, get, getElementType, hashCode, increment, indexOf, isEmptyOrNaN, isInteger, isSinglePrecision, set, sizeMethods inherited from class org.apache.sis.math.ArrayVector
compress, compress, isNaN, newInstance, verifyTypeMethods inherited from class org.apache.sis.math.Vector
backingVector, byteValue, compress, concatenate, copy, create, create, createConcatenate, createForDecimal, createSequence, createSequence, createSubSampling, createTransform, doubleValues, equals, floatValues, intValue, pick, range, repeat, repetitions, reverse, shortValue, subList, subSampling, subtract, toBacking, toString, transform, warningMethods inherited from class java.util.AbstractList
add, add, addAll, clear, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRangeMethods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArrayMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, streamMethods inherited from interface java.util.List
addAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDFor cross-version compatibility.- See Also:
-
-
Constructor Details
-
UnsignedLongs
UnsignedLongs(long[] array) Creates a new vector for the given array.
-
-
Method Details
-
isUnsigned
public boolean isUnsigned()Declares this vector as unsigned.- Overrides:
isUnsignedin classVector- Returns:
trueif the integer values shall be interpreted as unsigned values.
-
doubleValue
public double doubleValue(int index) Returns the unsigned long as adoublevalue.- Overrides:
doubleValuein classArrayVector.Longs- Parameters:
index- the index in the [0 … size-1] range.- Returns:
- the value at the given index.
- See Also:
-
floatValue
public float floatValue(int index) Returns the unsigned long as afloatvalue.- Overrides:
floatValuein classArrayVector.Longs- Parameters:
index- the index in the [0 … size-1] range.- Returns:
- the value at the given index.
- See Also:
-
longValue
public long longValue(int index) Returns the unsigned long as alongvalue, if possible.- Overrides:
longValuein classArrayVector.Longs- Parameters:
index- the index in the [0 … size-1] range.- Returns:
- the value at the given index.
-
stringValue
Returns the string representation at the given index.- Overrides:
stringValuein classArrayVector.Longs- Parameters:
index- the index in the [0 … size-1] range.- Returns:
- a string representation of the value at the given index (may be
null). - See Also:
-
range
Finds the minimum and maximum values in the array or in a subset of the array.- Overrides:
rangein classArrayVector.Longs- Parameters:
indices- supplier of indices of the values to examine for computing the range, ornullfor the 0, 1, 2, … n-1 sequence.n- number of indices to get from the supplier.- Returns:
- the range of all values at the given indices.
-