| Package | Description |
|---|---|
| de.javagl.nd.tuples.i |
Multidimensional tuples of
int values |
| Modifier and Type | Interface and Description |
|---|---|
interface |
MutableIntTuple
Interface describing an N-dimensional mutable tuple of
int values. |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractIntTuple
Abstract base implementation of a
IntTuple. |
class |
AbstractMutableIntTuple
Abstract base implementation of a
MutableIntTuple. |
| Modifier and Type | Method and Description |
|---|---|
static IntTuple |
IntTuples.constant(int size,
int value)
Returns a tuple with the specified size, where each
element is the given value.
|
static IntTuple |
IntTuples.reversed(IntTuple t)
Creates a new tuple that is a reversed view on the given
tuple.
|
default IntTuple |
IntTuple.subTuple(int fromIndex,
int toIndex) |
static IntTuple |
IntTuples.zero(int size)
Returns a tuple with the specified size, containing
all zeros.
|
| Modifier and Type | Method and Description |
|---|---|
static Comparator<IntTuple> |
IntTuples.comparator(Order order)
Returns a comparator that compares tuples based on the specified
Order. |
| Modifier and Type | Method and Description |
|---|---|
static MutableIntTuple |
IntTuples.add(IntTuple t0,
int value,
MutableIntTuple result)
Add the given value to all elements of the given input
tuples, and store the result in the given result tuple.
|
static MutableIntTuple |
IntTuples.add(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Add the given input tuples, and store the result in
the given result tuple.
|
static MutableIntTuple |
IntTuples.addScaled(IntTuple t0,
int factor,
IntTuple t1,
MutableIntTuple result)
Computes
t0+factor*t1, and stores the result in the given
result tuple. |
static MutableIntTuple |
IntTupleFunctions.apply(IntTuple t0,
IntTuple t1,
java.util.function.IntBinaryOperator op,
MutableIntTuple result)
Applies the given binary operator to each pair of elements from the
given tuples, and stores the result in the given result tuple.
|
static MutableIntTuple |
IntTupleFunctions.apply(IntTuple t0,
java.util.function.IntUnaryOperator op,
MutableIntTuple result)
Applies the given unary operator to element from the given tuple,
and stores the result in the given result tuple.
|
static boolean |
IntTuples.areElementsGreaterThan(IntTuple t,
int value)
Returns whether all elements of the given tuple
are greater than the given value.
|
static boolean |
IntTuples.areElementsGreaterThan(IntTuple t0,
IntTuple t1)
Returns whether one tuple is element-wise
greater than the other.
|
static boolean |
IntTuples.areElementsGreaterThanOrEqual(IntTuple t,
int value)
Returns whether all elements of the given tuple
are greater than or equal to the given value.
|
static boolean |
IntTuples.areElementsGreaterThanOrEqual(IntTuple t0,
IntTuple t1)
Returns whether one tuple is element-wise
greater than or equal to the other.
|
static boolean |
IntTuples.areElementsLessThan(IntTuple t,
int value)
Returns whether all elements of the given tuple
are less than the given value.
|
static boolean |
IntTuples.areElementsLessThan(IntTuple t0,
IntTuple t1)
Returns whether one tuple is element-wise
less than the other
|
static boolean |
IntTuples.areElementsLessThanOrEqual(IntTuple t,
int value)
Returns whether all elements of the given tuple
are less than or equal to the given value.
|
static boolean |
IntTuples.areElementsLessThanOrEqual(IntTuple t0,
IntTuple t1)
Returns whether one tuple is element-wise
less than or equal to the other
|
static List<Integer> |
IntTuples.asList(IntTuple t)
Returns a view on the given tuple as an unmodifiable list.
|
static MutableIntTuple |
IntTuples.clamp(IntTuple t,
int min,
int max,
MutableIntTuple result)
Clamp the components of the given tuple to be in the specified range,
and write the result into the given result tuple.
|
static MutableIntTuple |
IntTuples.clamp(IntTuple t,
IntTuple min,
IntTuple max,
MutableIntTuple result)
Clamp the components of the given tuple to be in the specified range,
and write the result into the given result tuple.
|
static int |
IntTuples.compareColexicographically(IntTuple t0,
IntTuple t1)
Compares two tuples colexicographically, starting with
the elements of the highest index.
|
static int |
IntTuples.compareLexicographically(IntTuple t0,
IntTuple t1)
Compares two tuples lexicographically, starting with
the elements of the lowest index.
|
static MutableIntTuple |
IntTuples.copy(IntTuple other)
Creates a new tuple which is a copy of
the given one.
|
static MutableIntTuple |
IntTuples.divide(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Divide the elements of the given input tuples, and store
the results in the given result tuple.
|
static int |
IntTuples.dot(IntTuple t0,
IntTuple t1)
Computes the dot product of the given tuples
|
static MutableIntTuple |
IntTupleFunctions.exclusiveScan(IntTuple t0,
int identity,
java.util.function.IntBinaryOperator op,
MutableIntTuple result)
Performs an exclusive scan on the elements of the given tuple, using
the provided identity value and associative accumulation function,
and returns the result.
|
static MutableIntTuple |
IntTupleFunctions.inclusiveScan(IntTuple t0,
java.util.function.IntBinaryOperator op,
MutableIntTuple result)
Performs an inclusive scan on the elements of the given tuple, using
the provided associative accumulation function, and returns the
result.
|
static boolean |
IntTuples.incrementColexicographically(IntTuple t,
IntTuple min,
IntTuple max,
MutableIntTuple result)
Colexicographically increment the given tuple in the given range, and
store the result in the given result tuple.
|
static boolean |
IntTuples.incrementLexicographically(IntTuple t,
IntTuple min,
IntTuple max,
MutableIntTuple result)
Lexicographically increment the given tuple in the given range, and
store the result in the given result tuple.
|
static int |
IntTuples.max(IntTuple t)
Computes the maximum value that occurs in the given tuple,
or
Integer.MIN_VALUE if the given tuple has a
size of 0. |
static MutableIntTuple |
IntTuples.max(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Compute the element-wise maximum of the the given input
tuples, and store the result in the given
result tuple.
|
static int |
IntTuples.min(IntTuple t)
Computes the minimum value that occurs in the given tuple,
or
Integer.MAX_VALUE if the given tuple has a
size of 0. |
static MutableIntTuple |
IntTuples.min(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Compute the element-wise minimum of the the given input
tuples, and store the result in the given
result tuple.
|
static MutableIntTuple |
IntTuples.multiply(IntTuple t0,
int factor,
MutableIntTuple result)
Multiply the given input tuple with the given factor, and
store the result in the given result tuple.
|
static MutableIntTuple |
IntTuples.multiply(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Multiply the elements of the given input tuples, and store
the results in the given result tuple.
|
static MutableIntTuple |
IntTuples.negate(IntTuple t0,
MutableIntTuple result)
Negates the given tuple, and store the result in the given result tuple.
|
static int |
IntTupleFunctions.reduce(IntTuple t0,
int identity,
java.util.function.IntBinaryOperator op)
Performs a reduction on the elements of the given tuple, using the
provided identity value and an associative accumulation function,
and returns the reduced value.
|
static MutableIntTuple |
IntTuples.reverse(IntTuple t,
MutableIntTuple result)
Reverse the given tuple.
|
static IntTuple |
IntTuples.reversed(IntTuple t)
Creates a new tuple that is a reversed view on the given
tuple.
|
default void |
MutableIntTuple.set(IntTuple other)
Set this tuple to be equal to the given one.
|
static MutableIntTuple |
IntTuples.subtract(IntTuple t0,
int value,
MutableIntTuple result)
Subtract the given value from all elements of the given input
tuple, and store the result in the given result tuple.
|
static MutableIntTuple |
IntTuples.subtract(IntTuple t0,
IntTuple t1,
MutableIntTuple result)
Subtract the given input tuples, and store the result in
the given result tuple.
|
static int[] |
IntTuples.toArray(IntTuple t)
Creates a new array from the contents of the given tuple
|
static MutableDoubleTuple |
IntTuples.toDoubleTuple(IntTuple intTuple)
Convert the given
IntTuple into a DoubleTuple |
static String |
IntTuples.toString(IntTuple tuple,
int maxNumLeadingElements,
int maxNumTrailingElements)
Returns a string representation of the given tuple using
IntTuples.toString(IntTuple, Locale, String, int, int) with
the default locale and format. |
static String |
IntTuples.toString(IntTuple tuple,
Locale locale,
String format,
int maxNumLeadingElements,
int maxNumTrailingElements)
Returns a string representation of the given tuple.
|
| Modifier and Type | Method and Description |
|---|---|
static MutableIntTuple |
IntTupleCollections.add(Collection<? extends IntTuple> tuples,
MutableIntTuple result)
Computes the component-wise sum of the given collection
of tuples.
|
static List<MutableIntTuple> |
IntTupleCollections.deepCopy(Collection<? extends IntTuple> tuples)
Returns a deep copy of the given collection of tuples.
|
static MutableIntTuple |
IntTupleCollections.max(Collection<? extends IntTuple> tuples,
MutableIntTuple result)
Computes the component-wise maximum of the given collection
of tuples.
|
static MutableIntTuple |
IntTupleCollections.min(Collection<? extends IntTuple> tuples,
MutableIntTuple result)
Computes the component-wise minimum of the given collection
of tuples.
|
Copyright © 2015. All Rights Reserved.