@UnstableApi
class CuesState


State holder that converts Player.Listener.onCues events into a State of List and tracks the availability of text commands.

Summary

Public constructors

CuesState(player: Player?)

Public functions

suspend Nothing?

Subscribes to updates from Player.Events and listens to Player.EVENT_CUES and Player.EVENT_AVAILABLE_COMMANDS_CHANGED to update the cues state.

Public properties

List<Cue>

The current list of cues to be displayed.

Public constructors

CuesState

CuesState(player: Player?)
Parameters
player: Player?

The Player whose cues are observed.

Public functions

observe

suspend fun observe(): Nothing?

Subscribes to updates from Player.Events and listens to Player.EVENT_CUES and Player.EVENT_AVAILABLE_COMMANDS_CHANGED to update the cues state.

Public properties

cues

val cues: List<Cue>

The current list of cues to be displayed. Defaults to an empty list and is also empty when Player.COMMAND_GET_TEXT is not available.