• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* //device/java/android/android/app/INotificationManager.aidl
2 **
3 ** Copyright 2007, The Android Open Source Project
4 **
5 ** Licensed under the Apache License, Version 2.0 (the "License");
6 ** you may not use this file except in compliance with the License.
7 ** You may obtain a copy of the License at
8 **
9 **     http://www.apache.org/licenses/LICENSE-2.0
10 **
11 ** Unless required by applicable law or agreed to in writing, software
12 ** distributed under the License is distributed on an "AS IS" BASIS,
13 ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 ** See the License for the specific language governing permissions and
15 ** limitations under the License.
16 */
17 
18 package android.app;
19 
20 import android.app.ITransientNotification;
21 import android.app.ITransientNotificationCallback;
22 import android.app.Notification;
23 import android.app.NotificationChannel;
24 import android.app.NotificationChannelGroup;
25 import android.app.NotificationHistory;
26 import android.app.NotificationManager;
27 import android.app.ICallNotificationEventCallback;
28 import android.content.AttributionSource;
29 import android.content.ComponentName;
30 import android.content.Intent;
31 import android.content.pm.ParceledListSlice;
32 import android.net.Uri;
33 import android.os.Bundle;
34 import android.os.UserHandle;
35 import android.service.notification.Adjustment;
36 import android.service.notification.Condition;
37 import android.service.notification.IConditionListener;
38 import android.service.notification.IConditionProvider;
39 import android.service.notification.INotificationListener;
40 import android.service.notification.NotificationListenerFilter;
41 import android.service.notification.StatusBarNotification;
42 import android.service.notification.ZenPolicy;
43 import android.app.AutomaticZenRule;
44 import android.service.notification.ZenModeConfig;
45 import android.service.notification.ZenDeviceEffects;
46 
47 /** {@hide} */
48 interface INotificationManager
49 {
50     @UnsupportedAppUsage
cancelAllNotifications(String pkg, int userId)51     void cancelAllNotifications(String pkg, int userId);
52 
clearData(String pkg, int uid, boolean fromApp)53     void clearData(String pkg, int uid, boolean fromApp);
enqueueTextToast(String pkg, IBinder token, CharSequence text, int duration, boolean isUiContext, int displayId, @nullable ITransientNotificationCallback callback)54     boolean enqueueTextToast(String pkg, IBinder token, CharSequence text, int duration, boolean isUiContext, int displayId, @nullable ITransientNotificationCallback callback);
enqueueToast(String pkg, IBinder token, ITransientNotification callback, int duration, boolean isUiContext, int displayId)55     boolean enqueueToast(String pkg, IBinder token, ITransientNotification callback, int duration, boolean isUiContext, int displayId);
cancelToast(String pkg, IBinder token)56     void cancelToast(String pkg, IBinder token);
finishToken(String pkg, IBinder token)57     void finishToken(String pkg, IBinder token);
58 
enqueueNotificationWithTag(String pkg, String opPkg, String tag, int id, in Notification notification, int userId)59     void enqueueNotificationWithTag(String pkg, String opPkg, String tag, int id,
60             in Notification notification, int userId);
61     @UnsupportedAppUsage
cancelNotificationWithTag(String pkg, String opPkg, String tag, int id, int userId)62     void cancelNotificationWithTag(String pkg, String opPkg, String tag, int id, int userId);
63 
isInCall(String pkg, int uid)64     boolean isInCall(String pkg, int uid);
setShowBadge(String pkg, int uid, boolean showBadge)65     void setShowBadge(String pkg, int uid, boolean showBadge);
canShowBadge(String pkg, int uid)66     boolean canShowBadge(String pkg, int uid);
hasSentValidMsg(String pkg, int uid)67     boolean hasSentValidMsg(String pkg, int uid);
isInInvalidMsgState(String pkg, int uid)68     boolean isInInvalidMsgState(String pkg, int uid);
hasUserDemotedInvalidMsgApp(String pkg, int uid)69     boolean hasUserDemotedInvalidMsgApp(String pkg, int uid);
setInvalidMsgAppDemoted(String pkg, int uid, boolean isDemoted)70     void setInvalidMsgAppDemoted(String pkg, int uid, boolean isDemoted);
hasSentValidBubble(String pkg, int uid)71     boolean hasSentValidBubble(String pkg, int uid);
setNotificationsEnabledForPackage(String pkg, int uid, boolean enabled)72     void setNotificationsEnabledForPackage(String pkg, int uid, boolean enabled);
73     /**
74      * Updates the notification's enabled state. Additionally locks importance for all of the
75      * notifications belonging to the app, such that future notifications aren't reconsidered for
76      * blocking helper.
77      */
setNotificationsEnabledWithImportanceLockForPackage(String pkg, int uid, boolean enabled)78     void setNotificationsEnabledWithImportanceLockForPackage(String pkg, int uid, boolean enabled);
79 
80     @UnsupportedAppUsage
areNotificationsEnabledForPackage(String pkg, int uid)81     boolean areNotificationsEnabledForPackage(String pkg, int uid);
areNotificationsEnabled(String pkg)82     boolean areNotificationsEnabled(String pkg);
getPackageImportance(String pkg)83     int getPackageImportance(String pkg);
isImportanceLocked(String pkg, int uid)84     boolean isImportanceLocked(String pkg, int uid);
85 
getAllowedAssistantAdjustments(String pkg)86     List<String> getAllowedAssistantAdjustments(String pkg);
allowAssistantAdjustment(String adjustmentType)87     void allowAssistantAdjustment(String adjustmentType);
disallowAssistantAdjustment(String adjustmentType)88     void disallowAssistantAdjustment(String adjustmentType);
89 
shouldHideSilentStatusIcons(String callingPkg)90     boolean shouldHideSilentStatusIcons(String callingPkg);
setHideSilentStatusIcons(boolean hide)91     void setHideSilentStatusIcons(boolean hide);
92 
setBubblesAllowed(String pkg, int uid, int bubblePreference)93     void setBubblesAllowed(String pkg, int uid, int bubblePreference);
areBubblesAllowed(String pkg)94     boolean areBubblesAllowed(String pkg);
areBubblesEnabled(in UserHandle user)95     boolean areBubblesEnabled(in UserHandle user);
getBubblePreferenceForPackage(String pkg, int uid)96     int getBubblePreferenceForPackage(String pkg, int uid);
97 
createNotificationChannelGroups(String pkg, in ParceledListSlice channelGroupList)98     void createNotificationChannelGroups(String pkg, in ParceledListSlice channelGroupList);
createNotificationChannels(String pkg, in ParceledListSlice channelsList)99     void createNotificationChannels(String pkg, in ParceledListSlice channelsList);
createNotificationChannelsForPackage(String pkg, int uid, in ParceledListSlice channelsList)100     void createNotificationChannelsForPackage(String pkg, int uid, in ParceledListSlice channelsList);
getConversations(boolean onlyImportant)101     ParceledListSlice getConversations(boolean onlyImportant);
getConversationsForPackage(String pkg, int uid)102     ParceledListSlice getConversationsForPackage(String pkg, int uid);
getNotificationChannelGroupsForPackage(String pkg, int uid, boolean includeDeleted)103     ParceledListSlice getNotificationChannelGroupsForPackage(String pkg, int uid, boolean includeDeleted);
getNotificationChannelGroupForPackage(String groupId, String pkg, int uid)104     NotificationChannelGroup getNotificationChannelGroupForPackage(String groupId, String pkg, int uid);
getPopulatedNotificationChannelGroupForPackage(String pkg, int uid, String groupId, boolean includeDeleted)105     NotificationChannelGroup getPopulatedNotificationChannelGroupForPackage(String pkg, int uid, String groupId, boolean includeDeleted);
getRecentBlockedNotificationChannelGroupsForPackage(String pkg, int uid)106     ParceledListSlice getRecentBlockedNotificationChannelGroupsForPackage(String pkg, int uid);
updateNotificationChannelGroupForPackage(String pkg, int uid, in NotificationChannelGroup group)107     void updateNotificationChannelGroupForPackage(String pkg, int uid, in NotificationChannelGroup group);
updateNotificationChannelForPackage(String pkg, int uid, in NotificationChannel channel)108     void updateNotificationChannelForPackage(String pkg, int uid, in NotificationChannel channel);
unlockNotificationChannel(String pkg, int uid, String channelId)109     void unlockNotificationChannel(String pkg, int uid, String channelId);
unlockAllNotificationChannels()110     void unlockAllNotificationChannels();
getNotificationChannel(String callingPkg, int userId, String pkg, String channelId)111     NotificationChannel getNotificationChannel(String callingPkg, int userId, String pkg, String channelId);
getConversationNotificationChannel(String callingPkg, int userId, String pkg, String channelId, boolean returnParentIfNoConversationChannel, String conversationId)112     NotificationChannel getConversationNotificationChannel(String callingPkg, int userId, String pkg, String channelId, boolean returnParentIfNoConversationChannel, String conversationId);
createConversationNotificationChannelForPackage(String pkg, int uid, in NotificationChannel parentChannel, String conversationId)113     void createConversationNotificationChannelForPackage(String pkg, int uid, in NotificationChannel parentChannel, String conversationId);
getNotificationChannelForPackage(String pkg, int uid, String channelId, String conversationId, boolean includeDeleted)114     NotificationChannel getNotificationChannelForPackage(String pkg, int uid, String channelId, String conversationId, boolean includeDeleted);
deleteNotificationChannel(String pkg, String channelId)115     void deleteNotificationChannel(String pkg, String channelId);
getNotificationChannels(String callingPkg, String targetPkg, int userId)116     ParceledListSlice getNotificationChannels(String callingPkg, String targetPkg, int userId);
getNotificationChannelsForPackage(String pkg, int uid, boolean includeDeleted)117     ParceledListSlice getNotificationChannelsForPackage(String pkg, int uid, boolean includeDeleted);
getNumNotificationChannelsForPackage(String pkg, int uid, boolean includeDeleted)118     int getNumNotificationChannelsForPackage(String pkg, int uid, boolean includeDeleted);
getDeletedChannelCount(String pkg, int uid)119     int getDeletedChannelCount(String pkg, int uid);
getBlockedChannelCount(String pkg, int uid)120     int getBlockedChannelCount(String pkg, int uid);
deleteNotificationChannelGroup(String pkg, String channelGroupId)121     void deleteNotificationChannelGroup(String pkg, String channelGroupId);
getNotificationChannelGroup(String pkg, String channelGroupId)122     NotificationChannelGroup getNotificationChannelGroup(String pkg, String channelGroupId);
getNotificationChannelGroups(String pkg)123     ParceledListSlice getNotificationChannelGroups(String pkg);
getNotificationChannelGroupsWithoutChannels(String pkg)124     ParceledListSlice getNotificationChannelGroupsWithoutChannels(String pkg);
onlyHasDefaultChannel(String pkg, int uid)125     boolean onlyHasDefaultChannel(String pkg, int uid);
areChannelsBypassingDnd()126     boolean areChannelsBypassingDnd();
getNotificationChannelsBypassingDnd(String pkg, int uid)127     ParceledListSlice getNotificationChannelsBypassingDnd(String pkg, int uid);
getPackagesBypassingDnd(int userId)128     ParceledListSlice getPackagesBypassingDnd(int userId);
getPackagesWithAnyChannels(int userId)129     List<String> getPackagesWithAnyChannels(int userId);
isPackagePaused(String pkg)130     boolean isPackagePaused(String pkg);
deleteNotificationHistoryItem(String pkg, int uid, long postedTime)131     void deleteNotificationHistoryItem(String pkg, int uid, long postedTime);
isPermissionFixed(String pkg, int userId)132     boolean isPermissionFixed(String pkg, int userId);
133 
silenceNotificationSound()134     void silenceNotificationSound();
135 
136     // TODO: Remove this when callers have been migrated to the equivalent
137     // INotificationListener method.
138     @UnsupportedAppUsage
getActiveNotifications(String callingPkg)139     StatusBarNotification[] getActiveNotifications(String callingPkg);
140     @EnforcePermission("ACCESS_NOTIFICATIONS")
getActiveNotificationsWithAttribution(String callingPkg, String callingAttributionTag)141     StatusBarNotification[] getActiveNotificationsWithAttribution(String callingPkg,
142             String callingAttributionTag);
143     @UnsupportedAppUsage(maxTargetSdk = 30, trackingBug = 170729553)
getHistoricalNotifications(String callingPkg, int count, boolean includeSnoozed)144     StatusBarNotification[] getHistoricalNotifications(String callingPkg, int count, boolean includeSnoozed);
145     @EnforcePermission("ACCESS_NOTIFICATIONS")
getHistoricalNotificationsWithAttribution(String callingPkg, String callingAttributionTag, int count, boolean includeSnoozed)146     StatusBarNotification[] getHistoricalNotificationsWithAttribution(String callingPkg,
147             String callingAttributionTag, int count, boolean includeSnoozed);
148 
149     @EnforcePermission("ACCESS_NOTIFICATIONS")
getNotificationHistory(String callingPkg, String callingAttributionTag)150     NotificationHistory getNotificationHistory(String callingPkg, String callingAttributionTag);
151 
registerListener(in INotificationListener listener, in ComponentName component, int userid)152     void registerListener(in INotificationListener listener, in ComponentName component, int userid);
unregisterListener(in INotificationListener listener, int userid)153     void unregisterListener(in INotificationListener listener, int userid);
154 
cancelNotificationFromListener(in INotificationListener token, String pkg, String tag, int id)155     void cancelNotificationFromListener(in INotificationListener token, String pkg, String tag, int id);
cancelNotificationsFromListener(in INotificationListener token, in String[] keys)156     void cancelNotificationsFromListener(in INotificationListener token, in String[] keys);
157 
snoozeNotificationUntilContextFromListener(in INotificationListener token, String key, String snoozeCriterionId)158     void snoozeNotificationUntilContextFromListener(in INotificationListener token, String key, String snoozeCriterionId);
snoozeNotificationUntilFromListener(in INotificationListener token, String key, long until)159     void snoozeNotificationUntilFromListener(in INotificationListener token, String key, long until);
160 
requestBindListener(in ComponentName component)161     void requestBindListener(in ComponentName component);
requestUnbindListener(in INotificationListener token)162     void requestUnbindListener(in INotificationListener token);
requestUnbindListenerComponent(in ComponentName component)163     void requestUnbindListenerComponent(in ComponentName component);
requestBindProvider(in ComponentName component)164     void requestBindProvider(in ComponentName component);
requestUnbindProvider(in IConditionProvider token)165     void requestUnbindProvider(in IConditionProvider token);
166 
167 
setNotificationsShownFromListener(in INotificationListener token, in String[] keys)168     void setNotificationsShownFromListener(in INotificationListener token, in String[] keys);
getActiveNotificationsFromListener(in INotificationListener token, in String[] keys, int trim)169     ParceledListSlice getActiveNotificationsFromListener(in INotificationListener token, in String[] keys, int trim);
getSnoozedNotificationsFromListener(in INotificationListener token, int trim)170     ParceledListSlice getSnoozedNotificationsFromListener(in INotificationListener token, int trim);
clearRequestedListenerHints(in INotificationListener token)171     void clearRequestedListenerHints(in INotificationListener token);
requestHintsFromListener(in INotificationListener token, int hints)172     void requestHintsFromListener(in INotificationListener token, int hints);
getHintsFromListener(in INotificationListener token)173     int getHintsFromListener(in INotificationListener token);
getHintsFromListenerNoToken()174     int getHintsFromListenerNoToken();
requestInterruptionFilterFromListener(in INotificationListener token, int interruptionFilter)175     void requestInterruptionFilterFromListener(in INotificationListener token, int interruptionFilter);
getInterruptionFilterFromListener(in INotificationListener token)176     int getInterruptionFilterFromListener(in INotificationListener token);
setOnNotificationPostedTrimFromListener(in INotificationListener token, int trim)177     void setOnNotificationPostedTrimFromListener(in INotificationListener token, int trim);
setInterruptionFilter(String pkg, int interruptionFilter, boolean fromUser)178     void setInterruptionFilter(String pkg, int interruptionFilter, boolean fromUser);
179 
createConversationNotificationChannelForPackageFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, String parentChannelId, String conversationId)180     NotificationChannel createConversationNotificationChannelForPackageFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, String parentChannelId, String conversationId);
updateNotificationChannelGroupFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, in NotificationChannelGroup group)181     void updateNotificationChannelGroupFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, in NotificationChannelGroup group);
updateNotificationChannelFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, in NotificationChannel channel)182     void updateNotificationChannelFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user, in NotificationChannel channel);
getNotificationChannelsFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user)183     ParceledListSlice getNotificationChannelsFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user);
getNotificationChannelGroupsFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user)184     ParceledListSlice getNotificationChannelGroupsFromPrivilegedListener(in INotificationListener token, String pkg, in UserHandle user);
185 
applyEnqueuedAdjustmentFromAssistant(in INotificationListener token, in Adjustment adjustment)186     void applyEnqueuedAdjustmentFromAssistant(in INotificationListener token, in Adjustment adjustment);
applyAdjustmentFromAssistant(in INotificationListener token, in Adjustment adjustment)187     void applyAdjustmentFromAssistant(in INotificationListener token, in Adjustment adjustment);
applyAdjustmentsFromAssistant(in INotificationListener token, in List<Adjustment> adjustments)188     void applyAdjustmentsFromAssistant(in INotificationListener token, in List<Adjustment> adjustments);
unsnoozeNotificationFromAssistant(in INotificationListener token, String key)189     void unsnoozeNotificationFromAssistant(in INotificationListener token, String key);
unsnoozeNotificationFromSystemListener(in INotificationListener token, String key)190     void unsnoozeNotificationFromSystemListener(in INotificationListener token, String key);
191 
getEffectsSuppressor()192     ComponentName getEffectsSuppressor();
matchesCallFilter(in Bundle extras)193     boolean matchesCallFilter(in Bundle extras);
cleanUpCallersAfter(long timeThreshold)194     void cleanUpCallersAfter(long timeThreshold);
isSystemConditionProviderEnabled(String path)195     boolean isSystemConditionProviderEnabled(String path);
196 
isNotificationListenerAccessGranted(in ComponentName listener)197     boolean isNotificationListenerAccessGranted(in ComponentName listener);
isNotificationListenerAccessGrantedForUser(in ComponentName listener, int userId)198     boolean isNotificationListenerAccessGrantedForUser(in ComponentName listener, int userId);
isNotificationAssistantAccessGranted(in ComponentName assistant)199     boolean isNotificationAssistantAccessGranted(in ComponentName assistant);
setNotificationListenerAccessGranted(in ComponentName listener, boolean enabled, boolean userSet)200     void setNotificationListenerAccessGranted(in ComponentName listener, boolean enabled, boolean userSet);
setNotificationAssistantAccessGranted(in ComponentName assistant, boolean enabled)201     void setNotificationAssistantAccessGranted(in ComponentName assistant, boolean enabled);
setNotificationListenerAccessGrantedForUser(in ComponentName listener, int userId, boolean enabled, boolean userSet)202     void setNotificationListenerAccessGrantedForUser(in ComponentName listener, int userId, boolean enabled, boolean userSet);
setNotificationAssistantAccessGrantedForUser(in ComponentName assistant, int userId, boolean enabled)203     void setNotificationAssistantAccessGrantedForUser(in ComponentName assistant, int userId, boolean enabled);
getEnabledNotificationListenerPackages()204     List<String> getEnabledNotificationListenerPackages();
getEnabledNotificationListeners(int userId)205     List<ComponentName> getEnabledNotificationListeners(int userId);
getAllowedNotificationAssistantForUser(int userId)206     ComponentName getAllowedNotificationAssistantForUser(int userId);
getAllowedNotificationAssistant()207     ComponentName getAllowedNotificationAssistant();
getDefaultNotificationAssistant()208     ComponentName getDefaultNotificationAssistant();
setNASMigrationDoneAndResetDefault(int userId, boolean loadFromConfig)209     void setNASMigrationDoneAndResetDefault(int userId, boolean loadFromConfig);
hasEnabledNotificationListener(String packageName, int userId)210     boolean hasEnabledNotificationListener(String packageName, int userId);
211 
212     @UnsupportedAppUsage
getZenMode()213     int getZenMode();
214     @UnsupportedAppUsage
getZenModeConfig()215     ZenModeConfig getZenModeConfig();
getConsolidatedNotificationPolicy()216     NotificationManager.Policy getConsolidatedNotificationPolicy();
setZenMode(int mode, in Uri conditionId, String reason, boolean fromUser)217     oneway void setZenMode(int mode, in Uri conditionId, String reason, boolean fromUser);
notifyConditions(String pkg, in IConditionProvider provider, in Condition[] conditions)218     oneway void notifyConditions(String pkg, in IConditionProvider provider, in Condition[] conditions);
isNotificationPolicyAccessGranted(String pkg)219     boolean isNotificationPolicyAccessGranted(String pkg);
getNotificationPolicy(String pkg)220     NotificationManager.Policy getNotificationPolicy(String pkg);
setNotificationPolicy(String pkg, in NotificationManager.Policy policy, boolean fromUser)221     void setNotificationPolicy(String pkg, in NotificationManager.Policy policy, boolean fromUser);
isNotificationPolicyAccessGrantedForPackage(String pkg)222     boolean isNotificationPolicyAccessGrantedForPackage(String pkg);
setNotificationPolicyAccessGranted(String pkg, boolean granted)223     void setNotificationPolicyAccessGranted(String pkg, boolean granted);
setNotificationPolicyAccessGrantedForUser(String pkg, int userId, boolean granted)224     void setNotificationPolicyAccessGrantedForUser(String pkg, int userId, boolean granted);
getDefaultZenPolicy()225     ZenPolicy getDefaultZenPolicy();
getAutomaticZenRule(String id)226     AutomaticZenRule getAutomaticZenRule(String id);
getAutomaticZenRules()227     ParceledListSlice getAutomaticZenRules();
addAutomaticZenRule(in AutomaticZenRule automaticZenRule, String pkg, boolean fromUser)228     String addAutomaticZenRule(in AutomaticZenRule automaticZenRule, String pkg, boolean fromUser);
updateAutomaticZenRule(String id, in AutomaticZenRule automaticZenRule, boolean fromUser)229     boolean updateAutomaticZenRule(String id, in AutomaticZenRule automaticZenRule, boolean fromUser);
removeAutomaticZenRule(String id, boolean fromUser)230     boolean removeAutomaticZenRule(String id, boolean fromUser);
removeAutomaticZenRules(String packageName, boolean fromUser)231     boolean removeAutomaticZenRules(String packageName, boolean fromUser);
getRuleInstanceCount(in ComponentName owner)232     int getRuleInstanceCount(in ComponentName owner);
getAutomaticZenRuleState(String id)233     int getAutomaticZenRuleState(String id);
setAutomaticZenRuleState(String id, in Condition condition)234     void setAutomaticZenRuleState(String id, in Condition condition);
setManualZenRuleDeviceEffects(in ZenDeviceEffects effects)235     void setManualZenRuleDeviceEffects(in ZenDeviceEffects effects);
236 
getBackupPayload(int user)237     byte[] getBackupPayload(int user);
applyRestore(in byte[] payload, int user)238     void applyRestore(in byte[] payload, int user);
239 
getAppActiveNotifications(String callingPkg, int userId)240     ParceledListSlice getAppActiveNotifications(String callingPkg, int userId);
241 
setNotificationDelegate(String callingPkg, String delegate)242     void setNotificationDelegate(String callingPkg, String delegate);
getNotificationDelegate(String callingPkg)243     String getNotificationDelegate(String callingPkg);
canNotifyAsPackage(String callingPkg, String targetPkg, int userId)244     boolean canNotifyAsPackage(String callingPkg, String targetPkg, int userId);
canUseFullScreenIntent(in AttributionSource attributionSource)245     boolean canUseFullScreenIntent(in AttributionSource attributionSource);
246 
setPrivateNotificationsAllowed(boolean allow)247     void setPrivateNotificationsAllowed(boolean allow);
getPrivateNotificationsAllowed()248     boolean getPrivateNotificationsAllowed();
249 
pullStats(long startNs, int report, boolean doAgg, out List<ParcelFileDescriptor> stats)250     long pullStats(long startNs, int report, boolean doAgg, out List<ParcelFileDescriptor> stats);
251 
getListenerFilter(in ComponentName cn, int userId)252     NotificationListenerFilter getListenerFilter(in ComponentName cn, int userId);
setListenerFilter(in ComponentName cn, int userId, in NotificationListenerFilter nlf)253     void setListenerFilter(in ComponentName cn, int userId, in NotificationListenerFilter nlf);
migrateNotificationFilter(in INotificationListener token, int defaultTypes, in List<String> disallowedPkgs)254     void migrateNotificationFilter(in INotificationListener token, int defaultTypes, in List<String> disallowedPkgs);
255 
256     @EnforcePermission("MANAGE_TOAST_RATE_LIMITING")
setToastRateLimitingEnabled(boolean enable)257     void setToastRateLimitingEnabled(boolean enable);
258 
259     @EnforcePermission(allOf={"INTERACT_ACROSS_USERS", "ACCESS_NOTIFICATIONS"})
registerCallNotificationEventListener(String packageName, in UserHandle userHandle, in ICallNotificationEventCallback listener)260     void registerCallNotificationEventListener(String packageName, in UserHandle userHandle, in ICallNotificationEventCallback listener);
261     @EnforcePermission(allOf={"INTERACT_ACROSS_USERS", "ACCESS_NOTIFICATIONS"})
unregisterCallNotificationEventListener(String packageName, in UserHandle userHandle, in ICallNotificationEventCallback listener)262     void unregisterCallNotificationEventListener(String packageName, in UserHandle userHandle, in ICallNotificationEventCallback listener);
263 
setCanBePromoted(String pkg, int uid, boolean promote, boolean fromUser)264     void setCanBePromoted(String pkg, int uid, boolean promote, boolean fromUser);
appCanBePromoted(String pkg, int uid)265     boolean appCanBePromoted(String pkg, int uid);
canBePromoted(String pkg)266     boolean canBePromoted(String pkg);
267 
setAdjustmentTypeSupportedState(in INotificationListener token, String key, boolean supported)268     void setAdjustmentTypeSupportedState(in INotificationListener token, String key, boolean supported);
getUnsupportedAdjustmentTypes()269     List<String> getUnsupportedAdjustmentTypes();
270 
getAllowedAdjustmentKeyTypes()271     int[] getAllowedAdjustmentKeyTypes();
setAssistantAdjustmentKeyTypeState(int type, boolean enabled)272     void setAssistantAdjustmentKeyTypeState(int type, boolean enabled);
getAdjustmentDeniedPackages(String key)273     String[] getAdjustmentDeniedPackages(String key);
isAdjustmentSupportedForPackage(String key, String pkg)274     boolean isAdjustmentSupportedForPackage(String key, String pkg);
setAdjustmentSupportedForPackage(String key, String pkg, boolean enabled)275     void setAdjustmentSupportedForPackage(String key, String pkg, boolean enabled);
276 
277     // TODO: b/389918945 - Remove once nm_binder_perf flags are going to Nextfood.
incrementCounter(String metricId)278     void incrementCounter(String metricId);
279 }
280