Added in API level 3

OnJetEventListener


interface OnJetEventListener
android.media.JetPlayer.OnJetEventListener

Handles the notification when the JET engine generates an event.

Summary

Public methods
abstract Unit
onJetEvent(player: JetPlayer!, segment: Short, track: Byte, channel: Byte, controller: Byte, value: Byte)

Callback for when the JET engine generates a new event.

abstract Unit
onJetNumQueuedSegmentUpdate(player: JetPlayer!, nbSegments: Int)

Callback for when JET's number of queued segments is updated.

abstract Unit
onJetPauseUpdate(player: JetPlayer!, paused: Int)

Callback for when JET pause state is updated.

abstract Unit
onJetUserIdUpdate(player: JetPlayer!, userId: Int, repeatCount: Int)

Callback for when JET's currently playing segment's userID is updated.

Public methods

onJetEvent

Added in API level 3
abstract fun onJetEvent(
    player: JetPlayer!,
    segment: Short,
    track: Byte,
    channel: Byte,
    controller: Byte,
    value: Byte
): Unit

Callback for when the JET engine generates a new event.

Parameters
player JetPlayer!: the JET player the event is coming from
segment Short: 8 bit unsigned value
track Byte: 6 bit unsigned value
channel Byte: 4 bit unsigned value
controller Byte: 7 bit unsigned value
value Byte: 7 bit unsigned value

onJetNumQueuedSegmentUpdate

Added in API level 3
abstract fun onJetNumQueuedSegmentUpdate(
    player: JetPlayer!,
    nbSegments: Int
): Unit

Callback for when JET's number of queued segments is updated.

Parameters
player JetPlayer!: the JET player the status update is coming from
nbSegments Int: the number of segments in the JET queue

onJetPauseUpdate

Added in API level 3
abstract fun onJetPauseUpdate(
    player: JetPlayer!,
    paused: Int
): Unit

Callback for when JET pause state is updated.

Parameters
player JetPlayer!: the JET player the status update is coming from
paused Int: indicates whether JET is paused (1) or not (0)

onJetUserIdUpdate

Added in API level 3
abstract fun onJetUserIdUpdate(
    player: JetPlayer!,
    userId: Int,
    repeatCount: Int
): Unit

Callback for when JET's currently playing segment's userID is updated.

Parameters
player JetPlayer!: the JET player the status update is coming from
userId Int: the ID of the currently playing segment
repeatCount Int: the repetition count for the segment (0 means it plays once)