Google は、黒人コミュニティに対する人種平等の促進に取り組んでいます。取り組みを見る

Callback

abstract class Callback
kotlin.Any
   ↳ android.support.v4.media.session.MediaSessionCompat.Callback

Receives transport controls, media buttons, and commands from controllers and the system. The callback may be set using setCallback.

Summary

Public constructors

Public methods

open Unit

Called when a MediaControllerCompat wants to add a QueueItem with the given description at the end of the play queue.

open Unit
onAddQueueItem(description: MediaDescriptionCompat!, index: Int)

Called when a MediaControllerCompat wants to add a QueueItem with the given description at the specified position in the play queue.

open Unit
onCommand(command: String!, extras: Bundle!, cb: ResultReceiver!)

Called when a controller has sent a custom command to this session.

open Unit
onCustomAction(action: String!, extras: Bundle!)

Called when a MediaControllerCompat wants a PlaybackStateCompat.CustomAction to be performed.

open Unit

Override to handle requests to fast forward.

open Boolean
onMediaButtonEvent(mediaButtonEvent: Intent!)

Override to handle media button events.

open Unit

Override to handle requests to pause playback.

open Unit

Override to handle requests to begin playback.

open Unit
onPlayFromMediaId(mediaId: String!, extras: Bundle!)

Override to handle requests to play a specific mediaId that was provided by your app.

open Unit
onPlayFromSearch(query: String!, extras: Bundle!)

Override to handle requests to begin playback from a search query.

open Unit
onPlayFromUri(uri: Uri!, extras: Bundle!)

Override to handle requests to play a specific media item represented by a URI.

open Unit

Override to handle requests to prepare playback.

open Unit
onPrepareFromMediaId(mediaId: String!, extras: Bundle!)

Override to handle requests to prepare for playing a specific mediaId that was provided by your app.

open Unit
onPrepareFromSearch(query: String!, extras: Bundle!)

Override to handle requests to prepare playback from a search query.

open Unit
onPrepareFromUri(uri: Uri!, extras: Bundle!)

Override to handle requests to prepare a specific media item represented by a URI.

open Unit

Called when a MediaControllerCompat wants to remove the first occurrence of the specified QueueItem with the given description in the play queue.

open Unit

Called when a MediaControllerCompat wants to remove a QueueItem at the specified position in the play queue.

open Unit

Override to handle requests to rewind.

open Unit
onSeekTo(pos: Long)

Override to handle requests to seek to a specific position in ms.

open Unit

Override to handle requests to enable/disable captioning.