docs/doc/reference/com/google/android/exoplayer2/ui/PlayerNotificationManager.NotificationListener.html
Package com.google.android.exoplayer2.ui
public static interfacePlayerNotificationManager.NotificationListener
A listener for changes to the notification.
All Methods Instance Methods Default Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| default void | onNotificationCancelled(int notificationId, boolean dismissedByUser) |
Called after the notification has been cancelled.
|
| default void | onNotificationPosted(int notificationId, Notification notification, boolean ongoing) |
Called each time after the notification has been posted.
|
-
default void onNotificationCancelled(int notificationId,
boolean dismissedByUser)
Called after the notification has been cancelled.
Parameters:notificationId - The id of the notification which has been cancelled.dismissedByUser - true if the notification is cancelled because the user dismissed the notification.
-
default void onNotificationPosted(int notificationId,[Notification](https://developer.android.com/reference/android/app/Notification.html "class or interface in android.app")notification,
boolean ongoing)
Called each time after the notification has been posted.
For a service, the ongoing flag can be used as an indicator as to whether it should be in the foreground.
Parameters:notificationId - The id of the notification which has been posted.notification - The Notification.ongoing - Whether the notification is ongoing.