public class Notification implements android.os.Parcelable {
method public deprecated java.lang.String getChannel();
+ method public static java.lang.Class<? extends android.app.Notification.Style> getNotificationStyleClass(java.lang.String);
method public deprecated long getTimeout();
method public deprecated void setLatestEventInfo(android.content.Context, java.lang.CharSequence, java.lang.CharSequence, android.app.PendingIntent);
}
}
+package android.service.notification {
+
+ public abstract class NotificationListenerService extends android.app.Service {
+ method public android.service.notification.StatusBarNotification[] getActiveNotifications(int);
+ method public android.service.notification.StatusBarNotification[] getActiveNotifications(java.lang.String[], int);
+ method public void registerAsSystemService(android.content.Context, android.content.ComponentName, int) throws android.os.RemoteException;
+ method public final void setOnNotificationPostedTrim(int);
+ method public final void snoozeNotification(java.lang.String, java.lang.String);
+ method public void unregisterAsSystemService() throws android.os.RemoteException;
+ field public static final int TRIM_FULL = 0; // 0x0
+ field public static final int TRIM_LIGHT = 1; // 0x1
+ }
+
+ public static class NotificationListenerService.Ranking {
+ method public java.util.List<java.lang.String> getAdditionalPeople();
+ method public java.util.List<android.service.notification.SnoozeCriterion> getSnoozeCriteria();
+ }
+
+}
+
package android.speech.tts {
public abstract class UtteranceProgressListener {
method public static void requestRebind(android.content.ComponentName);
method public final void requestUnbind();
method public final void setNotificationsShown(java.lang.String[]);
- method public final void snoozeNotification(java.lang.String, java.lang.String);
method public final void snoozeNotification(java.lang.String, long);
method public final void updateNotificationChannel(java.lang.String, android.os.UserHandle, android.app.NotificationChannel);
field public static final int HINT_HOST_DISABLE_CALL_EFFECTS = 4; // 0x4
public static class NotificationListenerService.Ranking {
ctor public NotificationListenerService.Ranking();
method public boolean canShowBadge();
- method public java.util.List<java.lang.String> getAdditionalPeople();
method public android.app.NotificationChannel getChannel();
method public int getImportance();
method public java.lang.CharSequence getImportanceExplanation();
method public java.lang.String getKey();
method public java.lang.String getOverrideGroupKey();
method public int getRank();
- method public java.util.List<android.service.notification.SnoozeCriterion> getSnoozeCriteria();
method public int getSuppressedVisualEffects();
method public boolean isAmbient();
method public boolean matchesInterruptionFilter();
public class Notification implements android.os.Parcelable {
method public deprecated java.lang.String getChannel();
+ method public static java.lang.Class<? extends android.app.Notification.Style> getNotificationStyleClass(java.lang.String);
method public deprecated long getTimeout();
method public deprecated void setLatestEventInfo(android.content.Context, java.lang.CharSequence, java.lang.CharSequence, android.app.PendingIntent);
}
}
+package android.service.notification {
+
+ public abstract class NotificationListenerService extends android.app.Service {
+ method public android.service.notification.StatusBarNotification[] getActiveNotifications(int);
+ method public android.service.notification.StatusBarNotification[] getActiveNotifications(java.lang.String[], int);
+ method public void registerAsSystemService(android.content.Context, android.content.ComponentName, int) throws android.os.RemoteException;
+ method public final void setOnNotificationPostedTrim(int);
+ method public final void snoozeNotification(java.lang.String, java.lang.String);
+ method public void unregisterAsSystemService() throws android.os.RemoteException;
+ field public static final int TRIM_FULL = 0; // 0x0
+ field public static final int TRIM_LIGHT = 1; // 0x1
+ }
+
+ public static class NotificationListenerService.Ranking {
+ method public java.util.List<java.lang.String> getAdditionalPeople();
+ method public java.util.List<android.service.notification.SnoozeCriterion> getSnoozeCriteria();
+ }
+
+}
+
package android.speech.tts {
public abstract class UtteranceProgressListener {
}
/**
- * @hide
+ * @removed
*/
@SystemApi
public static Class<? extends Style> getNotificationStyleClass(String templateClass) {
package android.service.notification;
-import android.Manifest;
import android.annotation.IntDef;
import android.annotation.NonNull;
-import android.annotation.TestApi;
-import android.app.NotificationChannel;
-import android.app.NotificationChannelGroup;
-import android.companion.CompanionDeviceManager;
-import android.os.Handler;
-import android.os.Looper;
-import android.os.Message;
-
-import android.annotation.SystemApi;
import android.annotation.SdkConstant;
+import android.annotation.SystemApi;
import android.app.INotificationManager;
import android.app.Notification;
import android.app.Notification.Builder;
+import android.app.NotificationChannel;
+import android.app.NotificationChannelGroup;
import android.app.NotificationManager;
import android.app.Service;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.pm.ParceledListSlice;
+import android.graphics.Bitmap;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.Icon;
-import android.graphics.Bitmap;
import android.os.Build;
import android.os.Bundle;
+import android.os.Handler;
import android.os.IBinder;
+import android.os.Looper;
+import android.os.Message;
import android.os.Parcel;
import android.os.Parcelable;
import android.os.RemoteException;
import android.util.ArraySet;
import android.util.Log;
import android.widget.RemoteViews;
+
import com.android.internal.annotations.GuardedBy;
import com.android.internal.os.SomeArgs;
* The full trim of the StatusBarNotification including all its features.
*
* @hide
+ * @removed
*/
@SystemApi
public static final int TRIM_FULL = 0;
* </ol>
*
* @hide
+ * @removed
*/
@SystemApi
public static final int TRIM_LIGHT = 1;
* @param snoozeCriterionId The{@link SnoozeCriterion#getId()} of a context to snooze the
* notification until.
* @hide
+ * @removed
*/
@SystemApi
- @TestApi
public final void snoozeNotification(String key, String snoozeCriterionId) {
if (!isBound()) return;
try {
* before performing this operation.
*
* @hide
+ * @removed
*
* @param trim trim of the notifications to be passed via {@link #onNotificationPosted}.
* See <code>TRIM_*</code> constants.
* current user). Useful when you don't know what's already been posted.
*
* @hide
+ * @removed
*
* @param trim trim of the notifications to be returned. See <code>TRIM_*</code> constants.
* @return An array of active notifications, sorted in natural order.
* more data out of those notifications.
*
* @hide
+ * @removed
*
* @param keys the keys of the notifications to request
* @param trim trim of the notifications to be returned. See <code>TRIM_*</code> constants.
* @param componentName the component that will consume the notification information
* @param currentUser the user to use as the stream filter
* @hide
+ * @removed
*/
@SystemApi
public void registerAsSystemService(Context context, ComponentName componentName,
* <p>This method will fail for listeners that were not registered
* with (@link registerAsService).
* @hide
+ * @removed
*/
@SystemApi
public void unregisterAsSystemService() throws RemoteException {
* If the {@link NotificationAssistantService} has added people to this notification, then
* this will be non-null.
* @hide
+ * @removed
*/
@SystemApi
- @TestApi
public List<String> getAdditionalPeople() {
return mOverridePeople;
}
* user interface displays options for snoozing notifications these criteria should be
* displayed as well.
* @hide
+ * @removed
*/
@SystemApi
- @TestApi
public List<SnoozeCriterion> getSnoozeCriteria() {
return mSnoozeCriteria;
}