MediaSessionService.MediaNotification

Added in 1.0.0
Deprecated in 1.3.0

class MediaSessionService.MediaNotification


Returned by onUpdateNotification for making session service foreground service to keep playback running in the background. It's highly recommended to show media style notification here.

Summary

Public constructors

MediaNotification(notificationId: Int, notification: Notification)

Default constructor

Public functions

Notification

Gets the notification.

Int

Gets the id of the id.

Public constructors

MediaNotification

Added in 1.0.0
Deprecated in 1.3.0
MediaNotification(notificationId: Int, notification: Notification)

Default constructor

Parameters
notificationId: Int

notification id to be used for notify.

notification: Notification

a notification to make session service foreground service. Media style notification is recommended here.

Public functions

getNotification

Added in 1.0.0
Deprecated in 1.3.0
fun getNotification(): Notification

Gets the notification.

Returns
Notification

the notification

getNotificationId

Added in 1.0.0
Deprecated in 1.3.0
fun getNotificationId(): Int

Gets the id of the id.

Returns
Int

the notification id