Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c39224c authored by Julia Reynolds's avatar Julia Reynolds Committed by Android (Google) Code Review
Browse files

Merge "Update documentation" into main

parents dadd78cf 42c59f1e
Loading
Loading
Loading
Loading
+13 −13
Original line number Diff line number Diff line
@@ -41153,19 +41153,19 @@ package android.service.notification {
    method public final android.service.notification.StatusBarNotification[] getSnoozedNotifications();
    method public final void migrateNotificationFilter(int, @Nullable java.util.List<java.lang.String>);
    method public android.os.IBinder onBind(android.content.Intent);
    method public void onInterruptionFilterChanged(int);
    method public void onListenerConnected();
    method public void onListenerDisconnected();
    method public void onListenerHintsChanged(int);
    method public void onNotificationChannelGroupModified(String, android.os.UserHandle, android.app.NotificationChannelGroup, int);
    method public void onNotificationChannelModified(String, android.os.UserHandle, android.app.NotificationChannel, int);
    method public void onNotificationPosted(android.service.notification.StatusBarNotification);
    method public void onNotificationPosted(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap);
    method public void onNotificationRankingUpdate(android.service.notification.NotificationListenerService.RankingMap);
    method public void onNotificationRemoved(android.service.notification.StatusBarNotification);
    method public void onNotificationRemoved(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap);
    method public void onNotificationRemoved(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap, int);
    method public void onSilentStatusBarIconsVisibilityChanged(boolean);
    method @UiThread public void onInterruptionFilterChanged(int);
    method @UiThread public void onListenerConnected();
    method @UiThread public void onListenerDisconnected();
    method @UiThread public void onListenerHintsChanged(int);
    method @UiThread public void onNotificationChannelGroupModified(String, android.os.UserHandle, android.app.NotificationChannelGroup, int);
    method @UiThread public void onNotificationChannelModified(String, android.os.UserHandle, android.app.NotificationChannel, int);
    method @UiThread public void onNotificationPosted(android.service.notification.StatusBarNotification);
    method @UiThread public void onNotificationPosted(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap);
    method @UiThread public void onNotificationRankingUpdate(android.service.notification.NotificationListenerService.RankingMap);
    method @UiThread public void onNotificationRemoved(android.service.notification.StatusBarNotification);
    method @UiThread public void onNotificationRemoved(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap);
    method @UiThread public void onNotificationRemoved(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap, int);
    method @UiThread public void onSilentStatusBarIconsVisibilityChanged(boolean);
    method public final void requestInterruptionFilter(int);
    method public final void requestListenerHints(int);
    method public static void requestRebind(android.content.ComponentName);
+1 −1
Original line number Diff line number Diff line
@@ -12891,7 +12891,7 @@ package android.service.notification {
  }
  public abstract class NotificationListenerService extends android.app.Service {
    method public void onNotificationRemoved(@NonNull android.service.notification.StatusBarNotification, @NonNull android.service.notification.NotificationListenerService.RankingMap, @NonNull android.service.notification.NotificationStats, int);
    method @UiThread public void onNotificationRemoved(@NonNull android.service.notification.StatusBarNotification, @NonNull android.service.notification.NotificationListenerService.RankingMap, @NonNull android.service.notification.NotificationStats, int);
  }
  public static class NotificationListenerService.Ranking {
+15 −0
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ import android.annotation.NonNull;
import android.annotation.Nullable;
import android.annotation.SdkConstant;
import android.annotation.SystemApi;
import android.annotation.UiThread;
import android.app.ActivityManager;
import android.app.INotificationManager;
import android.app.Notification;
@@ -468,6 +469,7 @@ public abstract class NotificationListenerService extends Service {
     *            object as well as its identifying information (tag and id) and source
     *            (package name).
     */
    @UiThread
    public void onNotificationPosted(StatusBarNotification sbn) {
        // optional
    }
@@ -481,6 +483,7 @@ public abstract class NotificationListenerService extends Service {
     * @param rankingMap The current ranking map that can be used to retrieve ranking information
     *                   for active notifications, including the newly posted one.
     */
    @UiThread
    public void onNotificationPosted(StatusBarNotification sbn, RankingMap rankingMap) {
        onNotificationPosted(sbn);
    }
@@ -499,6 +502,7 @@ public abstract class NotificationListenerService extends Service {
     *            and source (package name) used to post the {@link android.app.Notification} that
     *            was just removed.
     */
    @UiThread
    public void onNotificationRemoved(StatusBarNotification sbn) {
        // optional
    }
@@ -520,6 +524,7 @@ public abstract class NotificationListenerService extends Service {
     *                   for active notifications.
     *
     */
    @UiThread
    public void onNotificationRemoved(StatusBarNotification sbn, RankingMap rankingMap) {
        onNotificationRemoved(sbn);
    }
@@ -541,6 +546,7 @@ public abstract class NotificationListenerService extends Service {
     * @param rankingMap The current ranking map that can be used to retrieve ranking information
     *                   for active notifications.
     */
    @UiThread
    public void onNotificationRemoved(StatusBarNotification sbn, RankingMap rankingMap,
            @NotificationCancelReason int reason) {
        onNotificationRemoved(sbn, rankingMap);
@@ -552,6 +558,7 @@ public abstract class NotificationListenerService extends Service {
     *
     * @hide
     */
    @UiThread
    @SystemApi
    public void onNotificationRemoved(@NonNull StatusBarNotification sbn,
            @NonNull RankingMap rankingMap, @NonNull NotificationStats stats, int reason) {
@@ -563,6 +570,7 @@ public abstract class NotificationListenerService extends Service {
     * the notification manager.  You are safe to call {@link #getActiveNotifications()}
     * at this time.
     */
    @UiThread
    public void onListenerConnected() {
        // optional
    }
@@ -572,6 +580,7 @@ public abstract class NotificationListenerService extends Service {
     * notification manager.You will not receive any events after this call, and may only
     * call {@link #requestRebind(ComponentName)} at this time.
     */
    @UiThread
    public void onListenerDisconnected() {
        // optional
    }
@@ -582,6 +591,7 @@ public abstract class NotificationListenerService extends Service {
     * @param rankingMap The current ranking map that can be used to retrieve ranking information
     *                   for active notifications.
     */
    @UiThread
    public void onNotificationRankingUpdate(RankingMap rankingMap) {
        // optional
    }
@@ -592,6 +602,7 @@ public abstract class NotificationListenerService extends Service {
     *
     * @param hints The current {@link #getCurrentListenerHints() listener hints}.
     */
    @UiThread
    public void onListenerHintsChanged(int hints) {
        // optional
    }
@@ -603,6 +614,7 @@ public abstract class NotificationListenerService extends Service {
     * @param hideSilentStatusIcons whether or not status bar icons should be hidden for silent
     *                              notifications
     */
    @UiThread
    public void onSilentStatusBarIconsVisibilityChanged(boolean hideSilentStatusIcons) {
        // optional
    }
@@ -620,6 +632,7 @@ public abstract class NotificationListenerService extends Service {
     *                   {@link #NOTIFICATION_CHANNEL_OR_GROUP_UPDATED},
     *                   {@link #NOTIFICATION_CHANNEL_OR_GROUP_DELETED}.
     */
    @UiThread
    public void onNotificationChannelModified(String pkg, UserHandle user,
            NotificationChannel channel, @ChannelOrGroupModificationTypes int modificationType) {
        // optional
@@ -638,6 +651,7 @@ public abstract class NotificationListenerService extends Service {
     *                   {@link #NOTIFICATION_CHANNEL_OR_GROUP_UPDATED},
     *                   {@link #NOTIFICATION_CHANNEL_OR_GROUP_DELETED}.
     */
    @UiThread
    public void onNotificationChannelGroupModified(String pkg, UserHandle user,
            NotificationChannelGroup group, @ChannelOrGroupModificationTypes int modificationType) {
        // optional
@@ -650,6 +664,7 @@ public abstract class NotificationListenerService extends Service {
     * @param interruptionFilter The current
     *     {@link #getCurrentInterruptionFilter() interruption filter}.
     */
    @UiThread
    public void onInterruptionFilterChanged(int interruptionFilter) {
        // optional
    }