Package com.google.common.geometry
Interface PrimitiveArrays.Longs
-
- Enclosing class:
- PrimitiveArrays
static interface PrimitiveArrays.LongsAn array oflongs.Implementations will be thread-safe if the underlying data is not mutated. Users should ensure the underlying data is not mutated in order to get predictable behaviour. Any buffering should be done internally.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description static PrimitiveArrays.LongsfromImmutableLongArray(com.google.common.primitives.ImmutableLongArray immutableLongArray)Returns aPrimitiveArrays.LongswrappingimmutableLongArray.longget(int position)Returns thelongat positionposition.intlength()Returns the length of this array.default int[]toIntArray()Decodes and returns this array as anint[].
-
-
-
Method Detail
-
get
long get(int position)
Returns thelongat positionposition.Throws an
IndexOutOfBoundsExceptionif the absolute get on the underlying implementation fails.
-
length
int length()
Returns the length of this array.
-
fromImmutableLongArray
static PrimitiveArrays.Longs fromImmutableLongArray(com.google.common.primitives.ImmutableLongArray immutableLongArray)
Returns aPrimitiveArrays.LongswrappingimmutableLongArray.
-
toIntArray
default int[] toIntArray()
Decodes and returns this array as anint[].Throws an
IllegalArgumentExceptionif any value in this array is <Integer.MIN_VALUEor >Integer.MAX_VALUE.
-
-