Initialize a sorted container instance.
Optional iterable argument provides an initial iterable of values to initialize the sorted container.
Optionaliterable: Iterable<T, any, any>Initial values (optional).
Optionaloptions: SortedArrayConstructorOptions<C>An object that specifies characteristics about the sorted container.
StaticDEFAULT_The default load factor.
Override it with option loadFactor at construction time.
Return an iterator over the sorted container.
Iterating a sorted container while adding or deleting elements may throw an error or silently fail to iterate over all elements.
Lookup value at index in sorted container.
If index is out of range, returns undefined.
The zero-based index of the desired code unit. A negative index will count back from the last item.
The item located at the specified index, or undefined if index out of range.
Return an index to insert value in the sorted container.
If the value is already present, the insertion point will be before (to the left of) any existing values.
Value to find the insertion point of.
Insertion index of value in the sorted container.
Return an index to insert value in the sorted container.
Similar to bisectLeft, but if value is already present, the insertion point will be after (to the right of) any existing values.
Value to find the insertion point of.
Insertion index of value in the sorted container.
Remove all values from sorted container.
Return a shallow copy of the sorted container.
A new sorted container.
Return new SortedArray containing all values in both sequences.
Values in other do not need to be in sorted order.
Other iterable.
New SortedArray.
Return number of occurrences of value in the SortedArray.
Value to count in SortedArray.
Count.
Remove one value from sorted container if it is a member.
If value is not a member, do nothing.
Value to discard from SortedArray.
Returns true if an element in the SortedArray existed and has been removed, or false if the element does not exist.
Remove and return value at index in sorted container.
If the sorted container is empty or index is out of range, undefined is returned and the sorted container is not modified.
Negative indices count back from the last item.
Index of value. Negative integers count back from the last item in the array.
The removed value or undefined.
Removes elements from sorted container by index.
The zero-based location in the array from which to start removing elements. Negative integers count back from the last item in the array.
The zero-based location in the array at which to stop removing elements.
Negative integers count back from the last item in the array.
Elements up to but not including end are removed.
Returns an iterable of index-value pairs of elements in the SortedArray.
Return the first element in the sorted container that is equal to the provided value. If it is not found, undefined is returned.
With the default comparator and primitive elements, this method does not tell anything beyond whether the value exists in the sorted container. However, it can turn out to be useful with a custom comparator.
The value to find.
Executes a callback function once for each element in a SortedArray.
The function to execute.
OptionalthisArg: anyAn object to which the this keyword can refer in the callback function.
If thisArg is omitted, undefined is used.
Return true if value is an element of the SortedArray.
Search for value in SortedArray.
True if value in SortedArray.
Return first index of value in the sorted container, or -1 if value is not present.
Index must be between start and end for the value to be considered present.
Negative indices count back from the last item.
Value in sorted container.
The array index at which to start the search. If omitted, defaults to 0.
The array index at which to end the search. If omitted, defaults to the end of the sorted container.
The index of the first occurrence of value in the sorted container, or -1 if it is not present.
Create an iterator of values between minimum and maximum.
Both minimum and maximum default to undefined which is automatically inclusive of the beginning and end of the sorted container.
The argument includeMinimum and includeMaximum is a pair of booleans that indicates whether the minimum and maximum ought to be included in the range, respectively.
Both arguments default to true such that the range is inclusive of both minimum and maximum.
When reverse is true the values are yielded from the iterator in reverse order; reverse defaults to false.
Iterating a sorted container while adding or deleting elements may throw an error or silently fail to iterate over all elements.
Optionalminimum: CMinimum value to start iterating.
Optionalmaximum: CMaximum value to stop iterating.
Whether the minimum ought to be included in the range.
Whether the maximum ought to be included in the range.
Whether to yield values in reverse order.
Iterator.
Return an iterator that slices sorted container from start to end.
The start and end index are treated inclusive and exclusive, respectively.
A negative index will count back from the last item.
Both start and end default to undefined which is automatically inclusive of the beginning and end of the sorted container.
When reverse is true the values are yielded from the iterator in reverse order; reverse defaults to false.
Iterating a sorted container while adding or deleting elements may throw an error or silently fail to iterate over all elements.
Start index (inclusive).
Stop index (exclusive).
Whether to yield values in reverse order.
Iterator.
Returns an iterable of integers ranging from 0 (inclusive) to the length of the SortedArray (exclusive).
Remove the last element from the sorted container and return it. If the sorted container is empty, undefined is returned and the sorted container is not modified.
Popped value or undefined.
Return a reverse iterator over the sorted container.
Iterating a sorted container while adding or deleting elements may throw an error or silently fail to iterate over all elements.
Remove the first element from the sorted container and return it. If the sorted container is empty, undefined is returned and the sorted container is not modified.
Shifted value or undefined.
Returns a copy of a section of sorted container as an ordinary Array.
For both start and end, a negative index can be used to indicate an offset from the end of the array.
The beginning index of the specified portion of the array. If start is undefined, then the slice begins at index 0.
The end index of the specified portion of the array. This is exclusive of the element at the index end.
If end is undefined, then the slice extends to the end of the array.
Return sorted container as an ordinary Array.
Return a string representation of sorted container.
Update sorted container by adding all values from iterable.
Iterable of values to add.
Returns an iterable of values in the SortedArray.
SortedArray is a sorted mutable collection.
SortedArray values are maintained in sorted order.
SortedArray values must have a total ordering. The total ordering of values must not change while they are stored in the SortedArray.
Methods for adding values:
Methods for removing values:
Methods for looking up values:
Methods for iterating values:
Miscellaneous methods and properties: