IndexedValue (original) (raw)

kotlin-stdlib/kotlin.collections/IndexedValue

data class IndexedValue<out T>(val index: Int, val value: T)(source)

Data class representing a value from a collection or sequence, along with its index in that collection or sequence.

Since Kotlin

1.0

Constructors

IndexedValue

Link copied to clipboard

constructor(index: Int, value: T)

Properties

index

Link copied to clipboard

val index: Int

the index of the value in the collection or sequence.

Since Kotlin 1.0

value

Link copied to clipboard

val value: T

the underlying value.

Since Kotlin 1.0