CastEventListener

Listen the castSession connection event, and message receive event.

Functions

Link copied to clipboard
abstract fun onConnected()

This function is called when connect to a google cast device.

Link copied to clipboard
abstract fun onDisconnected()

This function is called when disconnect from a google cast device.

Link copied to clipboard
abstract fun onMessageReceive(namespace: String, message: String)

This function is called when receive the message from google cast device.

Link copied to clipboard
abstract fun onMessageReceiveError(errorMessage: String)

This function is called when error occur while receiving message.

Link copied to clipboard
abstract fun onMetaDataChanged(metadata: CastMetaData)

This function is called when metadata is changed and there are basic attributes of content in metadata.

Link copied to clipboard
abstract fun onRemoteClientPlayerStatusUpdated(playerState: Int)

This function is called when the remote media is loaded.

Link copied to clipboard
abstract fun onStartCasting()

This function is called when start casting media.

Link copied to clipboard
abstract fun onStopCasting()

This function is called when no media casting.