belongs to Maven artifact com.android.support:support-media-compat:28.0.0-alpha1
PlaybackStateCompat.CustomAction.Builder
public
static
final
class
PlaybackStateCompat.CustomAction.Builder
extends Object
java.lang.Object | |
↳ | android.support.v4.media.session.PlaybackStateCompat.CustomAction.Builder |
Builder for PlaybackStateCompat.CustomAction
objects.
Summary
Public constructors | |
---|---|
PlaybackStateCompat.CustomAction.Builder(String action, CharSequence name, int icon)
Creates a |
Public methods | |
---|---|
PlaybackStateCompat.CustomAction
|
build()
Build and return the |
PlaybackStateCompat.CustomAction.Builder
|
setExtras(Bundle extras)
Set optional extras for the |
Inherited methods | |
---|---|
From
class
java.lang.Object
|
Public constructors
PlaybackStateCompat.CustomAction.Builder
PlaybackStateCompat.CustomAction.Builder (String action, CharSequence name, int icon)
Creates a PlaybackStateCompat.CustomAction
builder with the id, name, and
icon set.
Parameters | |
---|---|
action |
String : The action of the PlaybackStateCompat.CustomAction . |
name |
CharSequence : The display name of the PlaybackStateCompat.CustomAction . This
name will be displayed along side the action if the UI
supports it. |
icon |
int : The icon resource id of the PlaybackStateCompat.CustomAction .
This resource id must be in the same package as the
MediaSessionCompat . It will be displayed with
the custom action if the UI supports it.
|
Public methods
build
PlaybackStateCompat.CustomAction build ()
Build and return the PlaybackStateCompat.CustomAction
instance with the
specified values.
Returns | |
---|---|
PlaybackStateCompat.CustomAction |
A new PlaybackStateCompat.CustomAction instance.
|
setExtras
PlaybackStateCompat.CustomAction.Builder setExtras (Bundle extras)
Set optional extras for the PlaybackStateCompat.CustomAction
. These extras
are meant to be consumed by a MediaControllerCompat
if it
knows how to handle them. Keys should be fully qualified (e.g.
"com.example.MY_ARG") to avoid collisions.
Parameters | |
---|---|
extras |
Bundle : Optional extras for the PlaybackStateCompat.CustomAction . |
Returns | |
---|---|
PlaybackStateCompat.CustomAction.Builder |
this. |
Interfaces
Classes
- MediaButtonReceiver
- MediaControllerCompat
- MediaControllerCompat.Callback
- MediaControllerCompat.PlaybackInfo
- MediaControllerCompat.TransportControls
- MediaSessionCompat
- MediaSessionCompat.Callback
- MediaSessionCompat.QueueItem
- MediaSessionCompat.Token
- ParcelableVolumeInfo
- PlaybackStateCompat
- PlaybackStateCompat.Builder
- PlaybackStateCompat.CustomAction
- PlaybackStateCompat.CustomAction.Builder