Android.Media.Session.MediaSessionManager.GetActiveSessions Method
Get a list of controllers for all ongoing sessions.

Syntax

[Android.Runtime.Register("getActiveSessions", "(Landroid/content/ComponentName;)Ljava/util/List;", "")]
public IList<MediaController> GetActiveSessions (Android.Content.ComponentName notificationListener)

Parameters

notificationListener
The enabled notification listener component. May be null.

Returns

Documentation for this section has not yet been entered.

Remarks

Get a list of controllers for all ongoing sessions. The controllers will be provided in priority order with the most important controller at index 0.

This requires the android.Manifest.permission.MEDIA_CONTENT_CONTROL permission be held by the calling app. You may also retrieve this list if your app is an enabled notification listener using the Android.Service.Notification.NotificationListenerService APIs, in which case you must pass the Android.Content.ComponentName of your enabled listener.

[Android Documentation]

Requirements

Namespace: Android.Media.Session
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0