Enum

abstract class Enum<E : Enum<E>>(name: String, ordinal: Int) : Comparable<E> (source)

The common base class of all enum classes. See the Kotlin language documentation for more information on enum classes.

Since Kotlin

1.2
abstract class Enum<E : Enum<E>>(name: String, ordinal: Int) : Comparable<E> (source)

The common base class of all enum classes. See the Kotlin language documentation for more information on enum classes.

Since Kotlin

1.0
abstract class Enum<E : Enum<E>>(name: String, ordinal: Int) : Comparable<E> (source)

The common base class of all enum classes. See the Kotlin language documentation for more information on enum classes.

Since Kotlin

1.1
abstract class Enum<E : Enum<E>>(val name: String, val ordinal: Int) : Comparable<E> (source)

The common base class of all enum classes. See the Kotlin language documentation for more information on enum classes.

Since Kotlin

1.3

Constructors

Link copied to clipboard
fun Enum(name: String, ordinal: Int)
fun Enum(name: String, ordinal: Int)
fun Enum(name: String, ordinal: Int)
fun Enum(name: String, ordinal: Int)

Types

Link copied to clipboard
object Companion
Since Kotlin 1.2
object Companion
Since Kotlin 1.0
object Companion
Since Kotlin 1.1
object Companion
Since Kotlin 1.3

Properties

Link copied to clipboard

Returns the name of this enum constant, exactly as declared in its enum declaration.

Since Kotlin 1.2

Returns the name of this enum constant, exactly as declared in its enum declaration.

Since Kotlin 1.0

Returns the name of this enum constant, exactly as declared in its enum declaration.

Since Kotlin 1.1
Since Kotlin 1.3
Link copied to clipboard

Returns the ordinal of this enumeration constant (its position in its enum declaration, where the initial constant is assigned an ordinal of zero).

Since Kotlin 1.2

Returns the ordinal of this enumeration constant (its position in its enum declaration, where the initial constant is assigned an ordinal of zero).

Since Kotlin 1.0

Returns the ordinal of this enumeration constant (its position in its enum declaration, where the initial constant is assigned an ordinal of zero).

Since Kotlin 1.1
Since Kotlin 1.3

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard