getWearTileState

Function

Android

Deprecated glance-wear-tiles is deprecated and will be removed

public suspend fun <T> getWearTileState(
    context: Context,
    definition: GlanceStateDefinition<T>,
    glanceId: GlanceId,
): T

Retrieve the state of a wear tile.

The state definition must be the one used for that particular wear tile.

Parameters

contextthe context used to create this state
definitionthe configuration that defines this state
glanceIdthe glance id of this particular tile service