java.lang.Object | |
↳ | android.media.session.MediaController.TransportControls |
Interface for controlling media playback on a session. This allows an app to send media transport commands to the session.
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Start fast forwarding.
| |||||||||||
Request that the player pause its playback and stay at its current
position.
| |||||||||||
Request that the player start its playback at its current position.
| |||||||||||
Request that the player start playback for a specific
Uri .
| |||||||||||
Request that the player start playback for a specific search query.
| |||||||||||
Start rewinding.
| |||||||||||
Move to a new location in the media stream.
| |||||||||||
Send the id and args from a custom action back for the
MediaSession to perform.
| |||||||||||
Send a custom action back for the
MediaSession to perform.
| |||||||||||
Rate the current content.
| |||||||||||
Skip to the next item.
| |||||||||||
Skip to the previous item.
| |||||||||||
Play an item with a specific id in the play queue.
| |||||||||||
Request that the player stop its playback; it may clear its state in
whatever way is appropriate.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Start fast forwarding. If playback is already fast forwarding this may increase the rate.
Request that the player pause its playback and stay at its current position.
Request that the player start its playback at its current position.
Request that the player start playback for a specific Uri
.
mediaId | The uri of the requested media. |
---|---|
extras | Optional extras that can include extra information about the media item to be played. |
Request that the player start playback for a specific search query. An empty or null query should be treated as a request to play any music.
query | The search query. |
---|---|
extras | Optional extras that can include extra information about the query. |
Start rewinding. If playback is already rewinding this may increase the rate.
Move to a new location in the media stream.
pos | Position to move to, in milliseconds. |
---|
Send the id and args from a custom action back for the MediaSession
to perform.
action | The action identifier of the PlaybackState.CustomAction as
specified by the MediaSession . |
---|---|
args | Optional arguments to supply to the MediaSession for this
custom action.
|
Send a custom action back for the MediaSession
to perform.
customAction | The action to perform. |
---|---|
args | Optional arguments to supply to the MediaSession for this
custom action.
|
Rate the current content. This will cause the rating to be set for
the current user. The Rating type must match the type returned by
getRatingType()
.
rating | The rating to set for the current content |
---|
Play an item with a specific id in the play queue. If you specify an id that is not in the play queue, the behavior is undefined.
Request that the player stop its playback; it may clear its state in whatever way is appropriate.