OrderedId64Array Class
A SortedArray of unique Id64Strings sorted in ascending order by the 64-bit unsigned integer values of the Ids.
@see CompressedId64Set for an immutable compact string representation.
Extends
Methods
Name | Description | |
---|---|---|
constructor(): OrderedId64Array | Construct a new, empty array. |
Inherited methods
Name | Inherited from | Description |
---|---|---|
_clear(): void Protected Inherited | SortedArray<Id64String> | Clears the contents of the sorted array. |
_extractArray(): string[] Protected Inherited | SortedArray<Id64String> | Extracts the sorted array as a T[] and empties the contents of this ReadonlySortedArray. |
_insert(value: string, onInsert?: (value: string) => any): number Protected Inherited | SortedArray<Id64String> | Attempts to insert a new value into the array at a position determined by the ordering. |
_remove(value: string): number Protected Inherited | SortedArray<Id64String> | Removes the first occurrence of a value comparing equal to the specified value from the array. |
[iterator](): Iterator<string, any, any> Inherited | SortedArray<Id64String> | Returns an iterator over the contents of the array in sorted order, suitable for use in for-of loops. |
clear(): void Inherited | SortedArray<Id64String> | Clears the contents of the sorted array. |
contains(value: string): boolean Inherited | SortedArray<Id64String> | Returns true if this array contains at least one value comparing equal to the specified value. |
extractArray(): string[] Inherited | SortedArray<Id64String> | Extracts the sorted array as a T[] and empties the contents of this SortedArray. |
findEqual(value: string): undefined | string Inherited | SortedArray<Id64String> | Looks up an element comparing equal to the specified value using binary search. |
findEquivalent(criterion: (element: string) => number): undefined | string Inherited | SortedArray<Id64String> | Find an element that compares as equivalent based on some criterion. |
forEach(func: (value: string) => void): void Inherited | SortedArray<Id64String> | Apply a function to each element in the array, in sorted order. |
get(index: number): undefined | string Inherited | SortedArray<Id64String> | Looks up an element by its index in the array. |
indexOf(value: string): number Inherited | SortedArray<Id64String> | Looks up the index of an element comparing equal to the specified value using binary search. |
indexOfEquivalent(criterion: (element: string) => number): number Inherited | SortedArray<Id64String> | Find the index of an element that compares as equivalent based on some criterion. |
insert(value: string, onInsert?: (value: string) => any): number Inherited | SortedArray<Id64String> | Attempts to insert a new value into the array at a position determined by the ordering. |
lowerBound(value: string): { equal: boolean, index: number } Protected Inherited | SortedArray<Id64String> | Computes the position at which the specified value should be inserted to maintain sorted order. |
remove(value: string): number Inherited | SortedArray<Id64String> | Removes the first occurrence of a value comparing equal to the specified value from the array. |
slice(start?: number, end?: number): SortedArray<string> Inherited | SortedArray<Id64String> | The equivalent of Array.slice. |
Properties
Name | Type | Description | |
---|---|---|---|
array Accessor ReadOnly | ReadonlyArray |
The underlying array of Ids. | |
ids Accessor ReadOnly | OrderedId64Iterable | An iterable that iterates over the Ids in sorted order. |
Inherited properties
Name | Type | Inherited from | Description |
---|---|---|---|
_array Protected Inherited | string[] | SortedArray<Id64String> | |
_clone Protected Readonly Inherited | CloneFunction<string> | SortedArray<Id64String> | |
_compare Protected Readonly Inherited | OrderedComparator<string> | SortedArray<Id64String> | |
_duplicatePolicy Protected Readonly Inherited | DuplicatePolicy | SortedArray<Id64String> | |
isEmpty Accessor Inherited ReadOnly | boolean | SortedArray<Id64String> | Returns true if the array contains no elements. |
length Accessor Inherited ReadOnly | number | SortedArray<Id64String> | The number of elements in the array |
Defined in
Last Updated: 17 December, 2024
Found something wrong, missing, or unclear on this page?Raise an issue in our repo.