EventIdentifierArray

class EventIdentifierArray

An array of event identifiers. When targeting the JVM, instances of this class are represented as long[].

Constructors

Link copied to clipboard
fun EventIdentifierArray(size: Int)

Creates a new array of the specified size, with all elements initialized to EventIdentifier.Unspecified.

Functions

Link copied to clipboard
operator fun contains(identifier: EventIdentifier): Boolean
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
operator fun get(index: Int): EventIdentifier

Returns the array element at the given index. This method can be called using the index operator.

Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
operator fun iterator(): EventIdentifierIterator

Creates an iterator over the elements of the array.

Link copied to clipboard
operator fun set(index: Int, value: EventIdentifier)

Sets the element at the given index to the given value. This method can be called using the index operator.

Link copied to clipboard
open override fun toString(): String

Properties

Link copied to clipboard
val size: Int

Returns the number of elements in the array.

Extensions

Link copied to clipboard
fun EventIdentifierArray.binarySearch(    element: EventIdentifier,     fromIndex: Int = 0,     toIndex: Int = size): Int

Searches this EventIdentifierArray for the provided element using the binary search algorithm. The array is expected to be sorted, otherwise the result is undefined.

Link copied to clipboard
fun EventIdentifierArray.binarySearchBySite(    element: SiteIdentifier,     fromIndex: Int = 0,     toIndex: Int = size): Int

Searches this EventIdentifierArray for the provided element using the binary search algorithm. The array is expected to be sorted by site identifiers, otherwise the result is undefined.

Link copied to clipboard
fun EventIdentifierArray.copyInto(    destination: EventIdentifierArray,     destinationOffset: Int = 0,     startIndex: Int = 0,     endIndex: Int = size): EventIdentifierArray

Copies this array or its subrange into the destination array and returns that array.

Link copied to clipboard
fun EventIdentifierArray.sort()

Sorts the array in-place.

Link copied to clipboard
Link copied to clipboard
fun EventIdentifierArray.toTypedArray(): Array<EventIdentifier>

Returns a typed object array containing all the elements of this primitive array.