EventListener
interface EventListener
android.media.MediaCas.EventListener |
An interface registered by the caller to setEventListener
to receives scheme-specific notifications from a MediaCas instance.
Summary
Public methods | |
---|---|
abstract Unit |
Notify the listener of a scheme-specific event from the CA system. |
open Unit |
onPluginStatusUpdate(mediaCas: MediaCas, status: Int, arg: Int) Notify the listener that the cas plugin status is updated. |
open Unit |
onResourceLost(mediaCas: MediaCas) Notify the listener that the session resources was lost. |
open Unit |
onSessionEvent(mediaCas: MediaCas, session: MediaCas.Session, event: Int, arg: Int, data: ByteArray?) Notify the listener of a scheme-specific session event from CA system. |
Public methods
onEvent
abstract fun onEvent(
mediaCas: MediaCas,
event: Int,
arg: Int,
data: ByteArray?
): Unit
Notify the listener of a scheme-specific event from the CA system.
Parameters | |
---|---|
mediaCas |
MediaCas: the MediaCas object to receive this event. This value cannot be null . |
event |
Int: an integer whose meaning is scheme-specific. |
arg |
Int: an integer whose meaning is scheme-specific. |
data |
ByteArray?: a byte array of data whose format and meaning are scheme-specific. This value may be null . |
onPluginStatusUpdate
open fun onPluginStatusUpdate(
mediaCas: MediaCas,
status: Int,
arg: Int
): Unit
Notify the listener that the cas plugin status is updated.
Parameters | |
---|---|
mediaCas |
MediaCas: the MediaCas object to receive this event. This value cannot be null . |
status |
Int: the plugin status which is updated. Value is android.media.MediaCas#PLUGIN_STATUS_PHYSICAL_MODULE_CHANGED , or android.media.MediaCas#PLUGIN_STATUS_SESSION_NUMBER_CHANGED |
arg |
Int: an integer whose meaning is specific to the status to be updated. |
onResourceLost
open fun onResourceLost(mediaCas: MediaCas): Unit
Notify the listener that the session resources was lost.
Parameters | |
---|---|
mediaCas |
MediaCas: the MediaCas object to receive this event. This value cannot be null . |
onSessionEvent
open fun onSessionEvent(
mediaCas: MediaCas,
session: MediaCas.Session,
event: Int,
arg: Int,
data: ByteArray?
): Unit
Notify the listener of a scheme-specific session event from CA system.
Parameters | |
---|---|
mediaCas |
MediaCas: the MediaCas object to receive this event. This value cannot be null . |
session |
MediaCas.Session: session object which the event is for. This value cannot be null . |
event |
Int: an integer whose meaning is scheme-specific. |
arg |
Int: an integer whose meaning is scheme-specific. |
data |
ByteArray?: a byte array of data whose format and meaning are scheme-specific. This value may be null . |