@SyntacticIterable public class Uint32Array extends Iterable<Integer>
Modifier and Type | Field and Description |
---|---|
ArrayBuffer |
buffer
The ArrayBuffer instance referenced by the array.
|
int |
byteLength
The length in bytes of the array.
|
int |
byteOffset
The offset in bytes of the array.
|
int |
BYTES_PER_ELEMENT
The size in bytes of each element in the array.
|
int |
length
The length of the array.
|
static Uint32Array |
prototype |
constructor
Modifier | Constructor and Description |
---|---|
protected |
Uint32Array() |
|
Uint32Array(ArrayBuffer buffer) |
|
Uint32Array(ArrayBuffer buffer,
int byteOffset) |
|
Uint32Array(ArrayBuffer buffer,
int byteOffset,
int length) |
|
Uint32Array(double[] array) |
|
Uint32Array(int length) |
|
Uint32Array(Uint32Array array) |
Modifier and Type | Method and Description |
---|---|
Double |
$get(int index) |
void |
$set(int index,
Integer value) |
Uint32Array |
copyWithin(double target,
int start)
Returns the this object after copying a section of the array identified by start and end
to the same array starting at position target
|
Uint32Array |
copyWithin(double target,
int start,
int end)
Returns the this object after copying a section of the array identified by start and end
to the same array starting at position target
|
IterableIterator<Tuple2<Double,Double>> |
entries()
Returns an array of key, value pairs for every entry in the array
|
Boolean |
every(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
Determines whether all the members of an array satisfy the specified test.
|
Boolean |
every(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn,
Object thisArg)
Determines whether all the members of an array satisfy the specified test.
|
Uint32Array |
fill(int value)
Returns the this object after filling the section identified by start and end with value
|
Uint32Array |
fill(int value,
int start)
Returns the this object after filling the section identified by start and end with value
|
Uint32Array |
fill(int value,
int start,
int end)
Returns the this object after filling the section identified by start and end with value
|
Uint32Array |
filter(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
Returns the elements of an array that meet the condition specified in a callback function.
|
Uint32Array |
filter(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn,
Object thisArg)
Returns the elements of an array that meet the condition specified in a callback function.
|
double |
find(TriFunction<Double,Double,Array<Double>,Boolean> predicate)
Returns the value of the first element in the array where predicate is true, and undefined
otherwise.
|
double |
find(TriFunction<Double,Double,Array<Double>,Boolean> predicate,
Object thisArg)
Returns the value of the first element in the array where predicate is true, and undefined
otherwise.
|
double |
findIndex(Function<Double,Boolean> predicate)
Returns the index of the first element in the array where predicate is true, and undefined
otherwise.
|
double |
findIndex(Function<Double,Boolean> predicate,
Object thisArg)
Returns the index of the first element in the array where predicate is true, and undefined
otherwise.
|
void |
forEach(TriConsumer<Double,Double,Uint32Array> callbackfn)
Performs the specified action for each element in an array.
|
void |
forEach(TriConsumer<Double,Double,Uint32Array> callbackfn,
Object thisArg)
Performs the specified action for each element in an array.
|
static Uint32Array |
from(ArrayLike<Double> arrayLike)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(ArrayLike<Double> arrayLike,
BiFunction<Double,Double,Double> mapfn)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(ArrayLike<Double> arrayLike,
BiFunction<Double,Double,Double> mapfn,
Object thisArg)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Double[] arrayLike)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Double[] arrayLike,
BiFunction<Double,Double,Double> mapfn)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Double[] arrayLike,
BiFunction<Double,Double,Double> mapfn,
Object thisArg)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Iterable<Double> arrayLike)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Iterable<Double> arrayLike,
BiFunction<Double,Double,Double> mapfn)
Creates an array from an array-like or iterable object.
|
static Uint32Array |
from(Iterable<Double> arrayLike,
BiFunction<Double,Double,Double> mapfn,
Object thisArg)
Creates an array from an array-like or iterable object.
|
int |
indexOf(int searchElement)
Returns the index of the first occurrence of a value in an array.
|
double |
indexOf(int searchElement,
int fromIndex)
Returns the index of the first occurrence of a value in an array.
|
Iterator<Integer> |
iterator()
From Iterable, to allow foreach loop (do not use directly).
|
String |
join()
Adds all the elements of an array separated by the specified separator string.
|
String |
join(String separator)
Adds all the elements of an array separated by the specified separator string.
|
IterableIterator<Double> |
keys()
Returns an list of keys in the array
|
int |
lastIndexOf(int searchElement)
Returns the index of the last occurrence of a value in an array.
|
double |
lastIndexOf(int searchElement,
int fromIndex)
Returns the index of the last occurrence of a value in an array.
|
Uint32Array |
map(TriFunction<Double,Double,Uint32Array,Double> callbackfn)
Calls a defined callback function on each element of an array, and returns an array that
contains the results.
|
Uint32Array |
map(TriFunction<Double,Double,Uint32Array,Double> callbackfn,
Object thisArg)
Calls a defined callback function on each element of an array, and returns an array that
contains the results.
|
static Uint32Array |
of(double... items)
Returns a new array from a set of elements.
|
double |
reduce(Function4<Double,Double,Double,Uint32Array,Double> callbackfn)
Calls the specified callback function for all the elements in an array.
|
double |
reduce(Function4<Double,Double,Double,Uint32Array,Double> callbackfn,
double initialValue)
Calls the specified callback function for all the elements in an array.
|
<U> U |
reduce(Function4<U,Double,Double,Uint32Array,U> callbackfn,
U initialValue)
Calls the specified callback function for all the elements in an array.
|
double |
reduceRight(Function4<Double,Double,Double,Uint32Array,Double> callbackfn)
Calls the specified callback function for all the elements in an array, in descending order.
|
double |
reduceRight(Function4<Double,Double,Double,Uint32Array,Double> callbackfn,
double initialValue)
Calls the specified callback function for all the elements in an array, in descending order.
|
<U> U |
reduceRight(Function4<U,Double,Double,Uint32Array,U> callbackfn,
U initialValue)
Calls the specified callback function for all the elements in an array, in descending order.
|
Uint32Array |
reverse()
Reverses the elements in an Array.
|
void |
set(int index,
int value)
Sets a value or an array of values.
|
void |
set(Uint32Array array)
Sets a value or an array of values.
|
void |
set(Uint32Array array,
int offset)
Sets a value or an array of values.
|
Uint32Array |
slice()
Returns a section of an array.
|
Uint32Array |
slice(int start)
Returns a section of an array.
|
Uint32Array |
slice(int start,
int end)
Returns a section of an array.
|
Boolean |
some(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
Determines whether the specified callback function returns true for any element of an array.
|
Boolean |
some(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn,
Object thisArg)
Determines whether the specified callback function returns true for any element of an array.
|
Uint32Array |
sort()
Sorts an array.
|
Uint32Array |
sort(BiFunction<Double,Double,Double> compareFn)
Sorts an array.
|
Uint32Array |
subarray(int begin)
Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements
at begin, inclusive, up to end, exclusive.
|
Uint32Array |
subarray(int begin,
int end)
Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements
at begin, inclusive, up to end, exclusive.
|
IterableIterator<Double> |
values()
Returns an list of values in the array
|
$applyStatic, $applyStatic, $delete, $delete, $get, $get, $set, $set, $super, assign, create, create, defineProperties, defineProperty, defineProperty, freeze, getOwnPropertyDescriptor, getOwnPropertyNames, getPrototypeOf, hasOwnProperty, hasOwnProperty, hasOwnProperty, isExtensible, isFrozen, isPrototypeOf, isSealed, keys, preventExtensions, propertyIsEnumerable, propertyIsEnumerable, propertyIsEnumerable, seal, toJSString, toLocaleString, toString, valueOf
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
forEach, spliterator
public int BYTES_PER_ELEMENT
public ArrayBuffer buffer
public int byteLength
public int byteOffset
public int length
public static Uint32Array prototype
public Uint32Array(int length)
public Uint32Array(Uint32Array array)
public Uint32Array(double[] array)
public Uint32Array(ArrayBuffer buffer, int byteOffset, int length)
public Uint32Array(ArrayBuffer buffer, int byteOffset)
public Uint32Array(ArrayBuffer buffer)
protected Uint32Array()
public Uint32Array copyWithin(double target, int start, int end)
target
- If target is negative, it is treated as length+target where length is the
length of the array.start
- If start is negative, it is treated as length+start. If end is negative, it
is treated as length+end.end
- If not specified, length of the this object is used as its default value.public IterableIterator<Tuple2<Double,Double>> entries()
public Boolean every(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn, Object thisArg)
callbackfn
- A function that accepts up to three arguments. The every method calls
the callbackfn function for each element in array1 until the callbackfn returns false,
or until the end of the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public Uint32Array fill(int value, int start, int end)
value
- value to fill array section withstart
- index to start filling the array at. If start is negative, it is treated as
length+start where length is the length of the array.end
- index to stop filling the array at. If end is negative, it is treated as
length+end.public Uint32Array filter(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn, Object thisArg)
callbackfn
- A function that accepts up to three arguments. The filter method calls
the callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public double find(TriFunction<Double,Double,Array<Double>,Boolean> predicate, Object thisArg)
predicate
- find calls predicate once for each element of the array, in ascending
order, until it finds one where predicate returns true. If such an element is found, find
immediately returns that element value. Otherwise, find returns undefined.thisArg
- If provided, it will be used as the this value for each invocation of
predicate. If it is not provided, undefined is used instead.public double findIndex(Function<Double,Boolean> predicate, Object thisArg)
predicate
- find calls predicate once for each element of the array, in ascending
order, until it finds one where predicate returns true. If such an element is found, find
immediately returns that element value. Otherwise, find returns undefined.thisArg
- If provided, it will be used as the this value for each invocation of
predicate. If it is not provided, undefined is used instead.public void forEach(TriConsumer<Double,Double,Uint32Array> callbackfn, Object thisArg)
callbackfn
- A function that accepts up to three arguments. forEach calls the
callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public double indexOf(int searchElement, int fromIndex)
searchElement
- The value to locate in the array.fromIndex
- The array index at which to begin the search. If fromIndex is omitted, the
search starts at index 0.public String join(String separator)
separator
- A string used to separate one element of an array from the next in the
resulting String. If omitted, the array elements are separated with a comma.public IterableIterator<Double> keys()
public double lastIndexOf(int searchElement, int fromIndex)
searchElement
- The value to locate in the array.fromIndex
- The array index at which to begin the search. If fromIndex is omitted, the
search starts at index 0.public Uint32Array map(TriFunction<Double,Double,Uint32Array,Double> callbackfn, Object thisArg)
callbackfn
- A function that accepts up to three arguments. The map method calls the
callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public double reduce(Function4<Double,Double,Double,Uint32Array,Double> callbackfn, double initialValue)
callbackfn
- A function that accepts up to four arguments. The reduce method calls the
callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an argument
instead of an array value.public <U> U reduce(Function4<U,Double,Double,Uint32Array,U> callbackfn, U initialValue)
callbackfn
- A function that accepts up to four arguments. The reduce method calls the
callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an argument
instead of an array value.public double reduceRight(Function4<Double,Double,Double,Uint32Array,Double> callbackfn, double initialValue)
callbackfn
- A function that accepts up to four arguments. The reduceRight method calls
the callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an
argument instead of an array value.public <U> U reduceRight(Function4<U,Double,Double,Uint32Array,U> callbackfn, U initialValue)
callbackfn
- A function that accepts up to four arguments. The reduceRight method calls
the callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an argument
instead of an array value.public Uint32Array reverse()
public void set(int index, int value)
index
- The index of the location to set.value
- The value to set.public void set(Uint32Array array, int offset)
array
- A typed or untyped array of values to set.offset
- The index in the current array at which the values are to be written.public Uint32Array slice(int start, int end)
start
- The beginning of the specified portion of the array.end
- The end of the specified portion of the array.public Boolean some(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn, Object thisArg)
callbackfn
- A function that accepts up to three arguments. The some method calls the
callbackfn function for each element in array1 until the callbackfn returns true, or until
the end of the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public Uint32Array sort(BiFunction<Double,Double,Double> compareFn)
compareFn
- The name of the function used to determine the order of the elements. If
omitted, the elements are sorted in ascending, ASCII character order.public Uint32Array subarray(int begin, int end)
begin
- The index of the beginning of the array.end
- The index of the end of the array.public IterableIterator<Double> values()
public Double $get(int index)
public void $set(int index, Integer value)
public static Uint32Array of(double... items)
items
- A set of elements to include in the new array object.public static Uint32Array from(ArrayLike<Double> arrayLike, BiFunction<Double,Double,Double> mapfn, Object thisArg)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public Uint32Array copyWithin(double target, int start)
target
- If target is negative, it is treated as length+target where length is the
length of the array.start
- If start is negative, it is treated as length+start. If end is negative, it
is treated as length+end.end
- If not specified, length of the this object is used as its default value.public Boolean every(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
callbackfn
- A function that accepts up to three arguments. The every method calls
the callbackfn function for each element in array1 until the callbackfn returns false,
or until the end of the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public Uint32Array fill(int value, int start)
value
- value to fill array section withstart
- index to start filling the array at. If start is negative, it is treated as
length+start where length is the length of the array.end
- index to stop filling the array at. If end is negative, it is treated as
length+end.public Uint32Array fill(int value)
value
- value to fill array section withstart
- index to start filling the array at. If start is negative, it is treated as
length+start where length is the length of the array.end
- index to stop filling the array at. If end is negative, it is treated as
length+end.public Uint32Array filter(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
callbackfn
- A function that accepts up to three arguments. The filter method calls
the callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public double find(TriFunction<Double,Double,Array<Double>,Boolean> predicate)
predicate
- find calls predicate once for each element of the array, in ascending
order, until it finds one where predicate returns true. If such an element is found, find
immediately returns that element value. Otherwise, find returns undefined.thisArg
- If provided, it will be used as the this value for each invocation of
predicate. If it is not provided, undefined is used instead.public double findIndex(Function<Double,Boolean> predicate)
predicate
- find calls predicate once for each element of the array, in ascending
order, until it finds one where predicate returns true. If such an element is found, find
immediately returns that element value. Otherwise, find returns undefined.thisArg
- If provided, it will be used as the this value for each invocation of
predicate. If it is not provided, undefined is used instead.public void forEach(TriConsumer<Double,Double,Uint32Array> callbackfn)
callbackfn
- A function that accepts up to three arguments. forEach calls the
callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public int indexOf(int searchElement)
searchElement
- The value to locate in the array.fromIndex
- The array index at which to begin the search. If fromIndex is omitted, the
search starts at index 0.public String join()
separator
- A string used to separate one element of an array from the next in the
resulting String. If omitted, the array elements are separated with a comma.public int lastIndexOf(int searchElement)
searchElement
- The value to locate in the array.fromIndex
- The array index at which to begin the search. If fromIndex is omitted, the
search starts at index 0.public Uint32Array map(TriFunction<Double,Double,Uint32Array,Double> callbackfn)
callbackfn
- A function that accepts up to three arguments. The map method calls the
callbackfn function one time for each element in the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public double reduce(Function4<Double,Double,Double,Uint32Array,Double> callbackfn)
callbackfn
- A function that accepts up to four arguments. The reduce method calls the
callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an argument
instead of an array value.public double reduceRight(Function4<Double,Double,Double,Uint32Array,Double> callbackfn)
callbackfn
- A function that accepts up to four arguments. The reduceRight method calls
the callbackfn function one time for each element in the array.initialValue
- If initialValue is specified, it is used as the initial value to start
the accumulation. The first call to the callbackfn function provides this value as an
argument instead of an array value.public void set(Uint32Array array)
array
- A typed or untyped array of values to set.offset
- The index in the current array at which the values are to be written.public Uint32Array slice(int start)
start
- The beginning of the specified portion of the array.end
- The end of the specified portion of the array.public Uint32Array slice()
start
- The beginning of the specified portion of the array.end
- The end of the specified portion of the array.public Boolean some(TriFunction<Double,Double,Uint32Array,Boolean> callbackfn)
callbackfn
- A function that accepts up to three arguments. The some method calls the
callbackfn function for each element in array1 until the callbackfn returns true, or until
the end of the array.thisArg
- An object to which the this keyword can refer in the callbackfn function.
If thisArg is omitted, undefined is used as the this value.public Uint32Array sort()
compareFn
- The name of the function used to determine the order of the elements. If
omitted, the elements are sorted in ascending, ASCII character order.public Uint32Array subarray(int begin)
begin
- The index of the beginning of the array.end
- The index of the end of the array.public static Uint32Array from(ArrayLike<Double> arrayLike, BiFunction<Double,Double,Double> mapfn)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(ArrayLike<Double> arrayLike)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Iterable<Double> arrayLike, BiFunction<Double,Double,Double> mapfn, Object thisArg)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Iterable<Double> arrayLike, BiFunction<Double,Double,Double> mapfn)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Iterable<Double> arrayLike)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Double[] arrayLike, BiFunction<Double,Double,Double> mapfn, Object thisArg)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Double[] arrayLike, BiFunction<Double,Double,Double> mapfn)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.public static Uint32Array from(Double[] arrayLike)
arrayLike
- An array-like or iterable object to convert to an array.mapfn
- A mapping function to call on every element of the array.thisArg
- Value of 'this' used to invoke the mapfn.