Share via


MediaSession2.SendSessionCommand Method

Definition

Sends a session command to a specific controller

[Android.Runtime.Register("sendSessionCommand", "(Landroid/media/MediaSession2$ControllerInfo;Landroid/media/Session2Command;Landroid/os/Bundle;)Ljava/lang/Object;", "GetSendSessionCommand_Landroid_media_MediaSession2_ControllerInfo_Landroid_media_Session2Command_Landroid_os_Bundle_Handler", ApiSince=29)]
public virtual Java.Lang.Object SendSessionCommand (Android.Media.MediaSession2.ControllerInfo controller, Android.Media.Session2Command command, Android.OS.Bundle? args);
[<Android.Runtime.Register("sendSessionCommand", "(Landroid/media/MediaSession2$ControllerInfo;Landroid/media/Session2Command;Landroid/os/Bundle;)Ljava/lang/Object;", "GetSendSessionCommand_Landroid_media_MediaSession2_ControllerInfo_Landroid_media_Session2Command_Landroid_os_Bundle_Handler", ApiSince=29)>]
abstract member SendSessionCommand : Android.Media.MediaSession2.ControllerInfo * Android.Media.Session2Command * Android.OS.Bundle -> Java.Lang.Object
override this.SendSessionCommand : Android.Media.MediaSession2.ControllerInfo * Android.Media.Session2Command * Android.OS.Bundle -> Java.Lang.Object

Parameters

controller
MediaSession2.ControllerInfo

the controller to get the session command

command
Session2Command

the session command

args
Bundle

optional arguments

Returns

a token which will be sent together in SessionCallback#onCommandResult when its result is received.

Attributes

Remarks

Java documentation for android.media.MediaSession2.sendSessionCommand(android.media.ControllerInfo, android.media.Session2Command, android.os.Bundle).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to