SemanticsConfiguration

class SemanticsConfiguration : SemanticsPropertyReceiver

Describes the semantics information associated with the owning component.

Summary

Public constructors

Public functions

operator T

Retrieves the value for the given property, if one has been set, If a value has not been set, throws IllegalStateException

T?
Any?> getOrElseNullable(
    key: SemanticsPropertyKey,
    defaultValue: () -> T?
)

Retrieves the value for the given property, if one has been set, If a value has not been set, returns the provided default value.

T?

Retrieves the value for the given property, if one has been set, If a value has not been set, returns null

open operator Unit
Any?> set(key: SemanticsPropertyKey, value: T)

Public constructors

SemanticsConfiguration

Added in 1.0.0
SemanticsConfiguration()

Public functions

get

Added in 1.0.0
operator fun Any?> get(key: SemanticsPropertyKey): T

Retrieves the value for the given property, if one has been set, If a value has not been set, throws IllegalStateException

getOrElseNullable

Added in 1.0.0
fun Any?> getOrElseNullable(
    key: SemanticsPropertyKey,
    defaultValue: () -> T?
): T?

Retrieves the value for the given property, if one has been set, If a value has not been set, returns the provided default value.

getOrNull

Added in 1.0.0
fun Any?> getOrNull(key: SemanticsPropertyKey): T?

Retrieves the value for the given property, if one has been set, If a value has not been set, returns null

set

open operator fun Any?> set(key: SemanticsPropertyKey, value: T): Unit