1 /* 2 * Copyright (C) 2006 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package android.app; 18 19 import android.app.ActivityManager.RunningTaskInfo; 20 import android.app.ActivityManager.RunningServiceInfo; 21 import android.app.ActivityManager.StackInfo; 22 import android.app.assist.AssistContent; 23 import android.app.assist.AssistStructure; 24 import android.content.ComponentName; 25 import android.content.ContentProviderNative; 26 import android.content.IContentProvider; 27 import android.content.IIntentReceiver; 28 import android.content.IIntentSender; 29 import android.content.Intent; 30 import android.content.IntentFilter; 31 import android.content.IntentSender; 32 import android.content.UriPermission; 33 import android.content.pm.ApplicationInfo; 34 import android.content.pm.ConfigurationInfo; 35 import android.content.pm.IPackageDataObserver; 36 import android.content.pm.ParceledListSlice; 37 import android.content.pm.ProviderInfo; 38 import android.content.pm.UserInfo; 39 import android.content.res.Configuration; 40 import android.graphics.Bitmap; 41 import android.graphics.Point; 42 import android.graphics.Rect; 43 import android.net.Uri; 44 import android.os.Bundle; 45 import android.os.Debug; 46 import android.os.IBinder; 47 import android.os.IInterface; 48 import android.os.Parcel; 49 import android.os.ParcelFileDescriptor; 50 import android.os.Parcelable; 51 import android.os.PersistableBundle; 52 import android.os.RemoteException; 53 import android.os.StrictMode; 54 import android.service.voice.IVoiceInteractionSession; 55 import com.android.internal.app.IVoiceInteractor; 56 import com.android.internal.os.IResultReceiver; 57 58 import java.util.List; 59 60 /** 61 * System private API for talking with the activity manager service. This 62 * provides calls from the application back to the activity manager. 63 * 64 * {@hide} 65 */ 66 public interface IActivityManager extends IInterface { startActivity(IApplicationThread caller, String callingPackage, Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options)67 public int startActivity(IApplicationThread caller, String callingPackage, Intent intent, 68 String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, 69 ProfilerInfo profilerInfo, Bundle options) throws RemoteException; startActivityAsUser(IApplicationThread caller, String callingPackage, Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options, int userId)70 public int startActivityAsUser(IApplicationThread caller, String callingPackage, Intent intent, 71 String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, 72 ProfilerInfo profilerInfo, Bundle options, int userId) throws RemoteException; startActivityAsCaller(IApplicationThread caller, String callingPackage, Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options, boolean ignoreTargetSecurity, int userId)73 public int startActivityAsCaller(IApplicationThread caller, String callingPackage, 74 Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, 75 int flags, ProfilerInfo profilerInfo, Bundle options, boolean ignoreTargetSecurity, 76 int userId) throws RemoteException; startActivityAndWait(IApplicationThread caller, String callingPackage, Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options, int userId)77 public WaitResult startActivityAndWait(IApplicationThread caller, String callingPackage, 78 Intent intent, String resolvedType, IBinder resultTo, String resultWho, 79 int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options, 80 int userId) throws RemoteException; startActivityWithConfig(IApplicationThread caller, String callingPackage, Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int startFlags, Configuration newConfig, Bundle options, int userId)81 public int startActivityWithConfig(IApplicationThread caller, String callingPackage, 82 Intent intent, String resolvedType, IBinder resultTo, String resultWho, 83 int requestCode, int startFlags, Configuration newConfig, 84 Bundle options, int userId) throws RemoteException; startActivityIntentSender(IApplicationThread caller, IntentSender intent, Intent fillInIntent, String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flagsMask, int flagsValues, Bundle options)85 public int startActivityIntentSender(IApplicationThread caller, 86 IntentSender intent, Intent fillInIntent, String resolvedType, 87 IBinder resultTo, String resultWho, int requestCode, 88 int flagsMask, int flagsValues, Bundle options) throws RemoteException; startVoiceActivity(String callingPackage, int callingPid, int callingUid, Intent intent, String resolvedType, IVoiceInteractionSession session, IVoiceInteractor interactor, int flags, ProfilerInfo profilerInfo, Bundle options, int userId)89 public int startVoiceActivity(String callingPackage, int callingPid, int callingUid, 90 Intent intent, String resolvedType, IVoiceInteractionSession session, 91 IVoiceInteractor interactor, int flags, ProfilerInfo profilerInfo, Bundle options, 92 int userId) throws RemoteException; startNextMatchingActivity(IBinder callingActivity, Intent intent, Bundle options)93 public boolean startNextMatchingActivity(IBinder callingActivity, 94 Intent intent, Bundle options) throws RemoteException; startActivityFromRecents(int taskId, Bundle options)95 public int startActivityFromRecents(int taskId, Bundle options) throws RemoteException; finishActivity(IBinder token, int code, Intent data, boolean finishTask)96 public boolean finishActivity(IBinder token, int code, Intent data, boolean finishTask) 97 throws RemoteException; finishSubActivity(IBinder token, String resultWho, int requestCode)98 public void finishSubActivity(IBinder token, String resultWho, int requestCode) throws RemoteException; finishActivityAffinity(IBinder token)99 public boolean finishActivityAffinity(IBinder token) throws RemoteException; finishVoiceTask(IVoiceInteractionSession session)100 public void finishVoiceTask(IVoiceInteractionSession session) throws RemoteException; releaseActivityInstance(IBinder token)101 public boolean releaseActivityInstance(IBinder token) throws RemoteException; releaseSomeActivities(IApplicationThread app)102 public void releaseSomeActivities(IApplicationThread app) throws RemoteException; willActivityBeVisible(IBinder token)103 public boolean willActivityBeVisible(IBinder token) throws RemoteException; registerReceiver(IApplicationThread caller, String callerPackage, IIntentReceiver receiver, IntentFilter filter, String requiredPermission, int userId)104 public Intent registerReceiver(IApplicationThread caller, String callerPackage, 105 IIntentReceiver receiver, IntentFilter filter, 106 String requiredPermission, int userId) throws RemoteException; unregisterReceiver(IIntentReceiver receiver)107 public void unregisterReceiver(IIntentReceiver receiver) throws RemoteException; broadcastIntent(IApplicationThread caller, Intent intent, String resolvedType, IIntentReceiver resultTo, int resultCode, String resultData, Bundle map, String[] requiredPermissions, int appOp, Bundle options, boolean serialized, boolean sticky, int userId)108 public int broadcastIntent(IApplicationThread caller, Intent intent, 109 String resolvedType, IIntentReceiver resultTo, int resultCode, 110 String resultData, Bundle map, String[] requiredPermissions, 111 int appOp, Bundle options, boolean serialized, boolean sticky, int userId) throws RemoteException; unbroadcastIntent(IApplicationThread caller, Intent intent, int userId)112 public void unbroadcastIntent(IApplicationThread caller, Intent intent, int userId) throws RemoteException; finishReceiver(IBinder who, int resultCode, String resultData, Bundle map, boolean abortBroadcast, int flags)113 public void finishReceiver(IBinder who, int resultCode, String resultData, Bundle map, 114 boolean abortBroadcast, int flags) throws RemoteException; attachApplication(IApplicationThread app)115 public void attachApplication(IApplicationThread app) throws RemoteException; activityResumed(IBinder token)116 public void activityResumed(IBinder token) throws RemoteException; activityIdle(IBinder token, Configuration config, boolean stopProfiling)117 public void activityIdle(IBinder token, Configuration config, 118 boolean stopProfiling) throws RemoteException; activityPaused(IBinder token)119 public void activityPaused(IBinder token) throws RemoteException; activityStopped(IBinder token, Bundle state, PersistableBundle persistentState, CharSequence description)120 public void activityStopped(IBinder token, Bundle state, 121 PersistableBundle persistentState, CharSequence description) throws RemoteException; activitySlept(IBinder token)122 public void activitySlept(IBinder token) throws RemoteException; activityDestroyed(IBinder token)123 public void activityDestroyed(IBinder token) throws RemoteException; getCallingPackage(IBinder token)124 public String getCallingPackage(IBinder token) throws RemoteException; getCallingActivity(IBinder token)125 public ComponentName getCallingActivity(IBinder token) throws RemoteException; getAppTasks(String callingPackage)126 public List<IAppTask> getAppTasks(String callingPackage) throws RemoteException; addAppTask(IBinder activityToken, Intent intent, ActivityManager.TaskDescription description, Bitmap thumbnail)127 public int addAppTask(IBinder activityToken, Intent intent, 128 ActivityManager.TaskDescription description, Bitmap thumbnail) throws RemoteException; getAppTaskThumbnailSize()129 public Point getAppTaskThumbnailSize() throws RemoteException; getTasks(int maxNum, int flags)130 public List<RunningTaskInfo> getTasks(int maxNum, int flags) throws RemoteException; getRecentTasks(int maxNum, int flags, int userId)131 public List<ActivityManager.RecentTaskInfo> getRecentTasks(int maxNum, 132 int flags, int userId) throws RemoteException; getTaskThumbnail(int taskId)133 public ActivityManager.TaskThumbnail getTaskThumbnail(int taskId) throws RemoteException; getServices(int maxNum, int flags)134 public List<RunningServiceInfo> getServices(int maxNum, int flags) throws RemoteException; getProcessesInErrorState()135 public List<ActivityManager.ProcessErrorStateInfo> getProcessesInErrorState() 136 throws RemoteException; moveTaskToFront(int task, int flags, Bundle options)137 public void moveTaskToFront(int task, int flags, Bundle options) throws RemoteException; moveActivityTaskToBack(IBinder token, boolean nonRoot)138 public boolean moveActivityTaskToBack(IBinder token, boolean nonRoot) throws RemoteException; moveTaskBackwards(int task)139 public void moveTaskBackwards(int task) throws RemoteException; moveTaskToStack(int taskId, int stackId, boolean toTop)140 public void moveTaskToStack(int taskId, int stackId, boolean toTop) throws RemoteException; resizeStack(int stackId, Rect bounds)141 public void resizeStack(int stackId, Rect bounds) throws RemoteException; getAllStackInfos()142 public List<StackInfo> getAllStackInfos() throws RemoteException; getStackInfo(int stackId)143 public StackInfo getStackInfo(int stackId) throws RemoteException; isInHomeStack(int taskId)144 public boolean isInHomeStack(int taskId) throws RemoteException; setFocusedStack(int stackId)145 public void setFocusedStack(int stackId) throws RemoteException; getFocusedStackId()146 public int getFocusedStackId() throws RemoteException; registerTaskStackListener(ITaskStackListener listener)147 public void registerTaskStackListener(ITaskStackListener listener) throws RemoteException; getTaskForActivity(IBinder token, boolean onlyRoot)148 public int getTaskForActivity(IBinder token, boolean onlyRoot) throws RemoteException; getContentProvider(IApplicationThread caller, String name, int userId, boolean stable)149 public ContentProviderHolder getContentProvider(IApplicationThread caller, 150 String name, int userId, boolean stable) throws RemoteException; getContentProviderExternal(String name, int userId, IBinder token)151 public ContentProviderHolder getContentProviderExternal(String name, int userId, IBinder token) 152 throws RemoteException; removeContentProvider(IBinder connection, boolean stable)153 public void removeContentProvider(IBinder connection, boolean stable) throws RemoteException; removeContentProviderExternal(String name, IBinder token)154 public void removeContentProviderExternal(String name, IBinder token) throws RemoteException; publishContentProviders(IApplicationThread caller, List<ContentProviderHolder> providers)155 public void publishContentProviders(IApplicationThread caller, 156 List<ContentProviderHolder> providers) throws RemoteException; refContentProvider(IBinder connection, int stableDelta, int unstableDelta)157 public boolean refContentProvider(IBinder connection, int stableDelta, int unstableDelta) 158 throws RemoteException; unstableProviderDied(IBinder connection)159 public void unstableProviderDied(IBinder connection) throws RemoteException; appNotRespondingViaProvider(IBinder connection)160 public void appNotRespondingViaProvider(IBinder connection) throws RemoteException; getRunningServiceControlPanel(ComponentName service)161 public PendingIntent getRunningServiceControlPanel(ComponentName service) 162 throws RemoteException; startService(IApplicationThread caller, Intent service, String resolvedType, String callingPackage, int userId)163 public ComponentName startService(IApplicationThread caller, Intent service, 164 String resolvedType, String callingPackage, int userId) throws RemoteException; stopService(IApplicationThread caller, Intent service, String resolvedType, int userId)165 public int stopService(IApplicationThread caller, Intent service, 166 String resolvedType, int userId) throws RemoteException; stopServiceToken(ComponentName className, IBinder token, int startId)167 public boolean stopServiceToken(ComponentName className, IBinder token, 168 int startId) throws RemoteException; setServiceForeground(ComponentName className, IBinder token, int id, Notification notification, boolean keepNotification)169 public void setServiceForeground(ComponentName className, IBinder token, 170 int id, Notification notification, boolean keepNotification) throws RemoteException; bindService(IApplicationThread caller, IBinder token, Intent service, String resolvedType, IServiceConnection connection, int flags, String callingPackage, int userId)171 public int bindService(IApplicationThread caller, IBinder token, Intent service, 172 String resolvedType, IServiceConnection connection, int flags, 173 String callingPackage, int userId) throws RemoteException; unbindService(IServiceConnection connection)174 public boolean unbindService(IServiceConnection connection) throws RemoteException; publishService(IBinder token, Intent intent, IBinder service)175 public void publishService(IBinder token, 176 Intent intent, IBinder service) throws RemoteException; unbindFinished(IBinder token, Intent service, boolean doRebind)177 public void unbindFinished(IBinder token, Intent service, 178 boolean doRebind) throws RemoteException; 179 /* oneway */ serviceDoneExecuting(IBinder token, int type, int startId, int res)180 public void serviceDoneExecuting(IBinder token, int type, int startId, 181 int res) throws RemoteException; peekService(Intent service, String resolvedType, String callingPackage)182 public IBinder peekService(Intent service, String resolvedType, String callingPackage) 183 throws RemoteException; 184 bindBackupAgent(ApplicationInfo appInfo, int backupRestoreMode)185 public boolean bindBackupAgent(ApplicationInfo appInfo, int backupRestoreMode) 186 throws RemoteException; clearPendingBackup()187 public void clearPendingBackup() throws RemoteException; backupAgentCreated(String packageName, IBinder agent)188 public void backupAgentCreated(String packageName, IBinder agent) throws RemoteException; unbindBackupAgent(ApplicationInfo appInfo)189 public void unbindBackupAgent(ApplicationInfo appInfo) throws RemoteException; killApplicationProcess(String processName, int uid)190 public void killApplicationProcess(String processName, int uid) throws RemoteException; 191 startInstrumentation(ComponentName className, String profileFile, int flags, Bundle arguments, IInstrumentationWatcher watcher, IUiAutomationConnection connection, int userId, String abiOverride)192 public boolean startInstrumentation(ComponentName className, String profileFile, 193 int flags, Bundle arguments, IInstrumentationWatcher watcher, 194 IUiAutomationConnection connection, int userId, 195 String abiOverride) throws RemoteException; finishInstrumentation(IApplicationThread target, int resultCode, Bundle results)196 public void finishInstrumentation(IApplicationThread target, 197 int resultCode, Bundle results) throws RemoteException; 198 getConfiguration()199 public Configuration getConfiguration() throws RemoteException; updateConfiguration(Configuration values)200 public void updateConfiguration(Configuration values) throws RemoteException; setRequestedOrientation(IBinder token, int requestedOrientation)201 public void setRequestedOrientation(IBinder token, 202 int requestedOrientation) throws RemoteException; getRequestedOrientation(IBinder token)203 public int getRequestedOrientation(IBinder token) throws RemoteException; 204 getActivityClassForToken(IBinder token)205 public ComponentName getActivityClassForToken(IBinder token) throws RemoteException; getPackageForToken(IBinder token)206 public String getPackageForToken(IBinder token) throws RemoteException; 207 getIntentSender(int type, String packageName, IBinder token, String resultWho, int requestCode, Intent[] intents, String[] resolvedTypes, int flags, Bundle options, int userId)208 public IIntentSender getIntentSender(int type, 209 String packageName, IBinder token, String resultWho, 210 int requestCode, Intent[] intents, String[] resolvedTypes, 211 int flags, Bundle options, int userId) throws RemoteException; cancelIntentSender(IIntentSender sender)212 public void cancelIntentSender(IIntentSender sender) throws RemoteException; clearApplicationUserData(final String packageName, final IPackageDataObserver observer, int userId)213 public boolean clearApplicationUserData(final String packageName, 214 final IPackageDataObserver observer, int userId) throws RemoteException; getPackageForIntentSender(IIntentSender sender)215 public String getPackageForIntentSender(IIntentSender sender) throws RemoteException; getUidForIntentSender(IIntentSender sender)216 public int getUidForIntentSender(IIntentSender sender) throws RemoteException; 217 handleIncomingUser(int callingPid, int callingUid, int userId, boolean allowAll, boolean requireFull, String name, String callerPackage)218 public int handleIncomingUser(int callingPid, int callingUid, int userId, boolean allowAll, 219 boolean requireFull, String name, String callerPackage) throws RemoteException; 220 setProcessLimit(int max)221 public void setProcessLimit(int max) throws RemoteException; getProcessLimit()222 public int getProcessLimit() throws RemoteException; 223 setProcessForeground(IBinder token, int pid, boolean isForeground)224 public void setProcessForeground(IBinder token, int pid, 225 boolean isForeground) throws RemoteException; 226 checkPermission(String permission, int pid, int uid)227 public int checkPermission(String permission, int pid, int uid) 228 throws RemoteException; checkPermissionWithToken(String permission, int pid, int uid, IBinder callerToken)229 public int checkPermissionWithToken(String permission, int pid, int uid, IBinder callerToken) 230 throws RemoteException; 231 checkUriPermission(Uri uri, int pid, int uid, int mode, int userId, IBinder callerToken)232 public int checkUriPermission(Uri uri, int pid, int uid, int mode, int userId, 233 IBinder callerToken) throws RemoteException; grantUriPermission(IApplicationThread caller, String targetPkg, Uri uri, int mode, int userId)234 public void grantUriPermission(IApplicationThread caller, String targetPkg, Uri uri, 235 int mode, int userId) throws RemoteException; revokeUriPermission(IApplicationThread caller, Uri uri, int mode, int userId)236 public void revokeUriPermission(IApplicationThread caller, Uri uri, int mode, int userId) 237 throws RemoteException; takePersistableUriPermission(Uri uri, int modeFlags, int userId)238 public void takePersistableUriPermission(Uri uri, int modeFlags, int userId) 239 throws RemoteException; releasePersistableUriPermission(Uri uri, int modeFlags, int userId)240 public void releasePersistableUriPermission(Uri uri, int modeFlags, int userId) 241 throws RemoteException; getPersistedUriPermissions( String packageName, boolean incoming)242 public ParceledListSlice<UriPermission> getPersistedUriPermissions( 243 String packageName, boolean incoming) throws RemoteException; 244 showWaitingForDebugger(IApplicationThread who, boolean waiting)245 public void showWaitingForDebugger(IApplicationThread who, boolean waiting) 246 throws RemoteException; 247 getMemoryInfo(ActivityManager.MemoryInfo outInfo)248 public void getMemoryInfo(ActivityManager.MemoryInfo outInfo) throws RemoteException; 249 killBackgroundProcesses(final String packageName, int userId)250 public void killBackgroundProcesses(final String packageName, int userId) 251 throws RemoteException; killAllBackgroundProcesses()252 public void killAllBackgroundProcesses() throws RemoteException; forceStopPackage(final String packageName, int userId)253 public void forceStopPackage(final String packageName, int userId) throws RemoteException; 254 255 // Note: probably don't want to allow applications access to these. setLockScreenShown(boolean shown)256 public void setLockScreenShown(boolean shown) throws RemoteException; 257 unhandledBack()258 public void unhandledBack() throws RemoteException; openContentUri(Uri uri)259 public ParcelFileDescriptor openContentUri(Uri uri) throws RemoteException; setDebugApp( String packageName, boolean waitForDebugger, boolean persistent)260 public void setDebugApp( 261 String packageName, boolean waitForDebugger, boolean persistent) 262 throws RemoteException; setAlwaysFinish(boolean enabled)263 public void setAlwaysFinish(boolean enabled) throws RemoteException; setActivityController(IActivityController watcher)264 public void setActivityController(IActivityController watcher) 265 throws RemoteException; 266 enterSafeMode()267 public void enterSafeMode() throws RemoteException; 268 noteWakeupAlarm(IIntentSender sender, int sourceUid, String sourcePkg, String tag)269 public void noteWakeupAlarm(IIntentSender sender, int sourceUid, String sourcePkg, String tag) 270 throws RemoteException; noteAlarmStart(IIntentSender sender, int sourceUid, String tag)271 public void noteAlarmStart(IIntentSender sender, int sourceUid, String tag) 272 throws RemoteException; noteAlarmFinish(IIntentSender sender, int sourceUid, String tag)273 public void noteAlarmFinish(IIntentSender sender, int sourceUid, String tag) 274 throws RemoteException; 275 killPids(int[] pids, String reason, boolean secure)276 public boolean killPids(int[] pids, String reason, boolean secure) throws RemoteException; killProcessesBelowForeground(String reason)277 public boolean killProcessesBelowForeground(String reason) throws RemoteException; 278 279 // Special low-level communication with activity manager. handleApplicationCrash(IBinder app, ApplicationErrorReport.CrashInfo crashInfo)280 public void handleApplicationCrash(IBinder app, 281 ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; handleApplicationWtf(IBinder app, String tag, boolean system, ApplicationErrorReport.CrashInfo crashInfo)282 public boolean handleApplicationWtf(IBinder app, String tag, boolean system, 283 ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; 284 285 // A StrictMode violation to be handled. The violationMask is a 286 // subset of the original StrictMode policy bitmask, with only the 287 // bit violated and penalty bits to be executed by the 288 // ActivityManagerService remaining set. handleApplicationStrictModeViolation(IBinder app, int violationMask, StrictMode.ViolationInfo crashInfo)289 public void handleApplicationStrictModeViolation(IBinder app, int violationMask, 290 StrictMode.ViolationInfo crashInfo) throws RemoteException; 291 292 /* 293 * This will deliver the specified signal to all the persistent processes. Currently only 294 * SIGUSR1 is delivered. All others are ignored. 295 */ signalPersistentProcesses(int signal)296 public void signalPersistentProcesses(int signal) throws RemoteException; 297 // Retrieve running application processes in the system getRunningAppProcesses()298 public List<ActivityManager.RunningAppProcessInfo> getRunningAppProcesses() 299 throws RemoteException; 300 // Retrieve info of applications installed on external media that are currently 301 // running. getRunningExternalApplications()302 public List<ApplicationInfo> getRunningExternalApplications() 303 throws RemoteException; 304 // Get memory information about the calling process. getMyMemoryState(ActivityManager.RunningAppProcessInfo outInfo)305 public void getMyMemoryState(ActivityManager.RunningAppProcessInfo outInfo) 306 throws RemoteException; 307 // Get device configuration getDeviceConfigurationInfo()308 public ConfigurationInfo getDeviceConfigurationInfo() throws RemoteException; 309 310 // Turn on/off profiling in a particular process. profileControl(String process, int userId, boolean start, ProfilerInfo profilerInfo, int profileType)311 public boolean profileControl(String process, int userId, boolean start, 312 ProfilerInfo profilerInfo, int profileType) throws RemoteException; 313 shutdown(int timeout)314 public boolean shutdown(int timeout) throws RemoteException; 315 stopAppSwitches()316 public void stopAppSwitches() throws RemoteException; resumeAppSwitches()317 public void resumeAppSwitches() throws RemoteException; 318 addPackageDependency(String packageName)319 public void addPackageDependency(String packageName) throws RemoteException; 320 killApplicationWithAppId(String pkg, int appid, String reason)321 public void killApplicationWithAppId(String pkg, int appid, String reason) 322 throws RemoteException; 323 closeSystemDialogs(String reason)324 public void closeSystemDialogs(String reason) throws RemoteException; 325 getProcessMemoryInfo(int[] pids)326 public Debug.MemoryInfo[] getProcessMemoryInfo(int[] pids) 327 throws RemoteException; 328 overridePendingTransition(IBinder token, String packageName, int enterAnim, int exitAnim)329 public void overridePendingTransition(IBinder token, String packageName, 330 int enterAnim, int exitAnim) throws RemoteException; 331 isUserAMonkey()332 public boolean isUserAMonkey() throws RemoteException; 333 setUserIsMonkey(boolean monkey)334 public void setUserIsMonkey(boolean monkey) throws RemoteException; 335 finishHeavyWeightApp()336 public void finishHeavyWeightApp() throws RemoteException; 337 convertFromTranslucent(IBinder token)338 public boolean convertFromTranslucent(IBinder token) throws RemoteException; convertToTranslucent(IBinder token, ActivityOptions options)339 public boolean convertToTranslucent(IBinder token, ActivityOptions options) throws RemoteException; notifyActivityDrawn(IBinder token)340 public void notifyActivityDrawn(IBinder token) throws RemoteException; getActivityOptions(IBinder token)341 public ActivityOptions getActivityOptions(IBinder token) throws RemoteException; 342 bootAnimationComplete()343 public void bootAnimationComplete() throws RemoteException; 344 setImmersive(IBinder token, boolean immersive)345 public void setImmersive(IBinder token, boolean immersive) throws RemoteException; isImmersive(IBinder token)346 public boolean isImmersive(IBinder token) throws RemoteException; isTopActivityImmersive()347 public boolean isTopActivityImmersive() throws RemoteException; isTopOfTask(IBinder token)348 public boolean isTopOfTask(IBinder token) throws RemoteException; 349 crashApplication(int uid, int initialPid, String packageName, String message)350 public void crashApplication(int uid, int initialPid, String packageName, 351 String message) throws RemoteException; 352 getProviderMimeType(Uri uri, int userId)353 public String getProviderMimeType(Uri uri, int userId) throws RemoteException; 354 newUriPermissionOwner(String name)355 public IBinder newUriPermissionOwner(String name) throws RemoteException; grantUriPermissionFromOwner(IBinder owner, int fromUid, String targetPkg, Uri uri, int mode, int sourceUserId, int targetUserId)356 public void grantUriPermissionFromOwner(IBinder owner, int fromUid, String targetPkg, 357 Uri uri, int mode, int sourceUserId, int targetUserId) throws RemoteException; revokeUriPermissionFromOwner(IBinder owner, Uri uri, int mode, int userId)358 public void revokeUriPermissionFromOwner(IBinder owner, Uri uri, 359 int mode, int userId) throws RemoteException; 360 checkGrantUriPermission(int callingUid, String targetPkg, Uri uri, int modeFlags, int userId)361 public int checkGrantUriPermission(int callingUid, String targetPkg, Uri uri, 362 int modeFlags, int userId) throws RemoteException; 363 364 // Cause the specified process to dump the specified heap. dumpHeap(String process, int userId, boolean managed, String path, ParcelFileDescriptor fd)365 public boolean dumpHeap(String process, int userId, boolean managed, String path, 366 ParcelFileDescriptor fd) throws RemoteException; 367 startActivities(IApplicationThread caller, String callingPackage, Intent[] intents, String[] resolvedTypes, IBinder resultTo, Bundle options, int userId)368 public int startActivities(IApplicationThread caller, String callingPackage, 369 Intent[] intents, String[] resolvedTypes, IBinder resultTo, 370 Bundle options, int userId) throws RemoteException; 371 getFrontActivityScreenCompatMode()372 public int getFrontActivityScreenCompatMode() throws RemoteException; setFrontActivityScreenCompatMode(int mode)373 public void setFrontActivityScreenCompatMode(int mode) throws RemoteException; getPackageScreenCompatMode(String packageName)374 public int getPackageScreenCompatMode(String packageName) throws RemoteException; setPackageScreenCompatMode(String packageName, int mode)375 public void setPackageScreenCompatMode(String packageName, int mode) 376 throws RemoteException; getPackageAskScreenCompat(String packageName)377 public boolean getPackageAskScreenCompat(String packageName) throws RemoteException; setPackageAskScreenCompat(String packageName, boolean ask)378 public void setPackageAskScreenCompat(String packageName, boolean ask) 379 throws RemoteException; 380 381 // Multi-user APIs switchUser(int userid)382 public boolean switchUser(int userid) throws RemoteException; startUserInBackground(int userid)383 public boolean startUserInBackground(int userid) throws RemoteException; stopUser(int userid, IStopUserCallback callback)384 public int stopUser(int userid, IStopUserCallback callback) throws RemoteException; getCurrentUser()385 public UserInfo getCurrentUser() throws RemoteException; isUserRunning(int userid, boolean orStopping)386 public boolean isUserRunning(int userid, boolean orStopping) throws RemoteException; getRunningUserIds()387 public int[] getRunningUserIds() throws RemoteException; 388 removeTask(int taskId)389 public boolean removeTask(int taskId) throws RemoteException; 390 registerProcessObserver(IProcessObserver observer)391 public void registerProcessObserver(IProcessObserver observer) throws RemoteException; unregisterProcessObserver(IProcessObserver observer)392 public void unregisterProcessObserver(IProcessObserver observer) throws RemoteException; 393 registerUidObserver(IUidObserver observer)394 public void registerUidObserver(IUidObserver observer) throws RemoteException; unregisterUidObserver(IUidObserver observer)395 public void unregisterUidObserver(IUidObserver observer) throws RemoteException; 396 isIntentSenderTargetedToPackage(IIntentSender sender)397 public boolean isIntentSenderTargetedToPackage(IIntentSender sender) throws RemoteException; 398 isIntentSenderAnActivity(IIntentSender sender)399 public boolean isIntentSenderAnActivity(IIntentSender sender) throws RemoteException; 400 getIntentForIntentSender(IIntentSender sender)401 public Intent getIntentForIntentSender(IIntentSender sender) throws RemoteException; 402 getTagForIntentSender(IIntentSender sender, String prefix)403 public String getTagForIntentSender(IIntentSender sender, String prefix) throws RemoteException; 404 updatePersistentConfiguration(Configuration values)405 public void updatePersistentConfiguration(Configuration values) throws RemoteException; 406 getProcessPss(int[] pids)407 public long[] getProcessPss(int[] pids) throws RemoteException; 408 showBootMessage(CharSequence msg, boolean always)409 public void showBootMessage(CharSequence msg, boolean always) throws RemoteException; 410 keyguardWaitingForActivityDrawn()411 public void keyguardWaitingForActivityDrawn() throws RemoteException; 412 keyguardGoingAway(boolean disableWindowAnimations, boolean keyguardGoingToNotificationShade)413 public void keyguardGoingAway(boolean disableWindowAnimations, 414 boolean keyguardGoingToNotificationShade) throws RemoteException; 415 shouldUpRecreateTask(IBinder token, String destAffinity)416 public boolean shouldUpRecreateTask(IBinder token, String destAffinity) 417 throws RemoteException; 418 navigateUpTo(IBinder token, Intent target, int resultCode, Intent resultData)419 public boolean navigateUpTo(IBinder token, Intent target, int resultCode, Intent resultData) 420 throws RemoteException; 421 422 // These are not public because you need to be very careful in how you 423 // manage your activity to make sure it is always the uid you expect. getLaunchedFromUid(IBinder activityToken)424 public int getLaunchedFromUid(IBinder activityToken) throws RemoteException; getLaunchedFromPackage(IBinder activityToken)425 public String getLaunchedFromPackage(IBinder activityToken) throws RemoteException; 426 registerUserSwitchObserver(IUserSwitchObserver observer)427 public void registerUserSwitchObserver(IUserSwitchObserver observer) throws RemoteException; unregisterUserSwitchObserver(IUserSwitchObserver observer)428 public void unregisterUserSwitchObserver(IUserSwitchObserver observer) throws RemoteException; 429 requestBugReport()430 public void requestBugReport() throws RemoteException; 431 inputDispatchingTimedOut(int pid, boolean aboveSystem, String reason)432 public long inputDispatchingTimedOut(int pid, boolean aboveSystem, String reason) 433 throws RemoteException; 434 getAssistContextExtras(int requestType)435 public Bundle getAssistContextExtras(int requestType) throws RemoteException; 436 requestAssistContextExtras(int requestType, IResultReceiver receiver, IBinder activityToken)437 public boolean requestAssistContextExtras(int requestType, IResultReceiver receiver, 438 IBinder activityToken) throws RemoteException; 439 reportAssistContextExtras(IBinder token, Bundle extras, AssistStructure structure, AssistContent content, Uri referrer)440 public void reportAssistContextExtras(IBinder token, Bundle extras, 441 AssistStructure structure, AssistContent content, Uri referrer) throws RemoteException; 442 launchAssistIntent(Intent intent, int requestType, String hint, int userHandle, Bundle args)443 public boolean launchAssistIntent(Intent intent, int requestType, String hint, int userHandle, 444 Bundle args) throws RemoteException; 445 isAssistDataAllowedOnCurrentActivity()446 public boolean isAssistDataAllowedOnCurrentActivity() throws RemoteException; 447 showAssistFromActivity(IBinder token, Bundle args)448 public boolean showAssistFromActivity(IBinder token, Bundle args) throws RemoteException; 449 killUid(int appId, int userId, String reason)450 public void killUid(int appId, int userId, String reason) throws RemoteException; 451 hang(IBinder who, boolean allowRestart)452 public void hang(IBinder who, boolean allowRestart) throws RemoteException; 453 reportActivityFullyDrawn(IBinder token)454 public void reportActivityFullyDrawn(IBinder token) throws RemoteException; 455 restart()456 public void restart() throws RemoteException; 457 performIdleMaintenance()458 public void performIdleMaintenance() throws RemoteException; 459 createVirtualActivityContainer(IBinder parentActivityToken, IActivityContainerCallback callback)460 public IActivityContainer createVirtualActivityContainer(IBinder parentActivityToken, 461 IActivityContainerCallback callback) throws RemoteException; 462 createStackOnDisplay(int displayId)463 public IActivityContainer createStackOnDisplay(int displayId) throws RemoteException; 464 deleteActivityContainer(IActivityContainer container)465 public void deleteActivityContainer(IActivityContainer container) throws RemoteException; 466 getActivityDisplayId(IBinder activityToken)467 public int getActivityDisplayId(IBinder activityToken) throws RemoteException; 468 startLockTaskModeOnCurrent()469 public void startLockTaskModeOnCurrent() throws RemoteException; 470 startLockTaskMode(int taskId)471 public void startLockTaskMode(int taskId) throws RemoteException; 472 startLockTaskMode(IBinder token)473 public void startLockTaskMode(IBinder token) throws RemoteException; 474 stopLockTaskMode()475 public void stopLockTaskMode() throws RemoteException; 476 stopLockTaskModeOnCurrent()477 public void stopLockTaskModeOnCurrent() throws RemoteException; 478 isInLockTaskMode()479 public boolean isInLockTaskMode() throws RemoteException; 480 getLockTaskModeState()481 public int getLockTaskModeState() throws RemoteException; 482 showLockTaskEscapeMessage(IBinder token)483 public void showLockTaskEscapeMessage(IBinder token) throws RemoteException; 484 setTaskDescription(IBinder token, ActivityManager.TaskDescription values)485 public void setTaskDescription(IBinder token, ActivityManager.TaskDescription values) 486 throws RemoteException; setTaskResizeable(int taskId, boolean resizeable)487 public void setTaskResizeable(int taskId, boolean resizeable) throws RemoteException; resizeTask(int taskId, Rect bounds)488 public void resizeTask(int taskId, Rect bounds) throws RemoteException; getTaskDescriptionIcon(String filename)489 public Bitmap getTaskDescriptionIcon(String filename) throws RemoteException; 490 startInPlaceAnimationOnFrontMostApplication(ActivityOptions opts)491 public void startInPlaceAnimationOnFrontMostApplication(ActivityOptions opts) 492 throws RemoteException; 493 requestVisibleBehind(IBinder token, boolean visible)494 public boolean requestVisibleBehind(IBinder token, boolean visible) throws RemoteException; isBackgroundVisibleBehind(IBinder token)495 public boolean isBackgroundVisibleBehind(IBinder token) throws RemoteException; backgroundResourcesReleased(IBinder token)496 public void backgroundResourcesReleased(IBinder token) throws RemoteException; 497 notifyLaunchTaskBehindComplete(IBinder token)498 public void notifyLaunchTaskBehindComplete(IBinder token) throws RemoteException; notifyEnterAnimationComplete(IBinder token)499 public void notifyEnterAnimationComplete(IBinder token) throws RemoteException; 500 notifyCleartextNetwork(int uid, byte[] firstPacket)501 public void notifyCleartextNetwork(int uid, byte[] firstPacket) throws RemoteException; 502 setDumpHeapDebugLimit(String processName, int uid, long maxMemSize, String reportPackage)503 public void setDumpHeapDebugLimit(String processName, int uid, long maxMemSize, 504 String reportPackage) throws RemoteException; dumpHeapFinished(String path)505 public void dumpHeapFinished(String path) throws RemoteException; 506 setVoiceKeepAwake(IVoiceInteractionSession session, boolean keepAwake)507 public void setVoiceKeepAwake(IVoiceInteractionSession session, boolean keepAwake) 508 throws RemoteException; updateLockTaskPackages(int userId, String[] packages)509 public void updateLockTaskPackages(int userId, String[] packages) throws RemoteException; updateDeviceOwner(String packageName)510 public void updateDeviceOwner(String packageName) throws RemoteException; 511 getPackageProcessState(String packageName, String callingPackage)512 public int getPackageProcessState(String packageName, String callingPackage) 513 throws RemoteException; 514 setProcessMemoryTrimLevel(String process, int uid, int level)515 public boolean setProcessMemoryTrimLevel(String process, int uid, int level) 516 throws RemoteException; 517 isRootVoiceInteraction(IBinder token)518 public boolean isRootVoiceInteraction(IBinder token) throws RemoteException; 519 520 /* 521 * Private non-Binder interfaces 522 */ testIsSystemReady()523 /* package */ boolean testIsSystemReady(); 524 525 /** Information you can retrieve about a particular application. */ 526 public static class ContentProviderHolder implements Parcelable { 527 public final ProviderInfo info; 528 public IContentProvider provider; 529 public IBinder connection; 530 public boolean noReleaseNeeded; 531 ContentProviderHolder(ProviderInfo _info)532 public ContentProviderHolder(ProviderInfo _info) { 533 info = _info; 534 } 535 536 @Override describeContents()537 public int describeContents() { 538 return 0; 539 } 540 541 @Override writeToParcel(Parcel dest, int flags)542 public void writeToParcel(Parcel dest, int flags) { 543 info.writeToParcel(dest, 0); 544 if (provider != null) { 545 dest.writeStrongBinder(provider.asBinder()); 546 } else { 547 dest.writeStrongBinder(null); 548 } 549 dest.writeStrongBinder(connection); 550 dest.writeInt(noReleaseNeeded ? 1 : 0); 551 } 552 553 public static final Parcelable.Creator<ContentProviderHolder> CREATOR 554 = new Parcelable.Creator<ContentProviderHolder>() { 555 @Override 556 public ContentProviderHolder createFromParcel(Parcel source) { 557 return new ContentProviderHolder(source); 558 } 559 560 @Override 561 public ContentProviderHolder[] newArray(int size) { 562 return new ContentProviderHolder[size]; 563 } 564 }; 565 ContentProviderHolder(Parcel source)566 private ContentProviderHolder(Parcel source) { 567 info = ProviderInfo.CREATOR.createFromParcel(source); 568 provider = ContentProviderNative.asInterface( 569 source.readStrongBinder()); 570 connection = source.readStrongBinder(); 571 noReleaseNeeded = source.readInt() != 0; 572 } 573 } 574 575 /** Information returned after waiting for an activity start. */ 576 public static class WaitResult implements Parcelable { 577 public int result; 578 public boolean timeout; 579 public ComponentName who; 580 public long thisTime; 581 public long totalTime; 582 WaitResult()583 public WaitResult() { 584 } 585 586 @Override describeContents()587 public int describeContents() { 588 return 0; 589 } 590 591 @Override writeToParcel(Parcel dest, int flags)592 public void writeToParcel(Parcel dest, int flags) { 593 dest.writeInt(result); 594 dest.writeInt(timeout ? 1 : 0); 595 ComponentName.writeToParcel(who, dest); 596 dest.writeLong(thisTime); 597 dest.writeLong(totalTime); 598 } 599 600 public static final Parcelable.Creator<WaitResult> CREATOR 601 = new Parcelable.Creator<WaitResult>() { 602 @Override 603 public WaitResult createFromParcel(Parcel source) { 604 return new WaitResult(source); 605 } 606 607 @Override 608 public WaitResult[] newArray(int size) { 609 return new WaitResult[size]; 610 } 611 }; 612 WaitResult(Parcel source)613 private WaitResult(Parcel source) { 614 result = source.readInt(); 615 timeout = source.readInt() != 0; 616 who = ComponentName.readFromParcel(source); 617 thisTime = source.readLong(); 618 totalTime = source.readLong(); 619 } 620 } 621 622 String descriptor = "android.app.IActivityManager"; 623 624 // Please keep these transaction codes the same -- they are also 625 // sent by C++ code. 626 int HANDLE_APPLICATION_CRASH_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+1; 627 int START_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+2; 628 int UNHANDLED_BACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+3; 629 int OPEN_CONTENT_URI_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+4; 630 631 // Remaining non-native transaction codes. 632 int FINISH_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+10; 633 int REGISTER_RECEIVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+11; 634 int UNREGISTER_RECEIVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+12; 635 int BROADCAST_INTENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+13; 636 int UNBROADCAST_INTENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+14; 637 int FINISH_RECEIVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+15; 638 int ATTACH_APPLICATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+16; 639 int ACTIVITY_IDLE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+17; 640 int ACTIVITY_PAUSED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+18; 641 int ACTIVITY_STOPPED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+19; 642 int GET_CALLING_PACKAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+20; 643 int GET_CALLING_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+21; 644 int GET_TASKS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+22; 645 int MOVE_TASK_TO_FRONT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+23; 646 647 int MOVE_TASK_BACKWARDS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+25; 648 int GET_TASK_FOR_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+26; 649 650 int GET_CONTENT_PROVIDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+28; 651 int PUBLISH_CONTENT_PROVIDERS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+29; 652 int REF_CONTENT_PROVIDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+30; 653 int FINISH_SUB_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+31; 654 int GET_RUNNING_SERVICE_CONTROL_PANEL_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+32; 655 int START_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+33; 656 int STOP_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+34; 657 int BIND_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+35; 658 int UNBIND_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+36; 659 int PUBLISH_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+37; 660 int ACTIVITY_RESUMED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+38; 661 int SET_DEBUG_APP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+41; 662 int SET_ALWAYS_FINISH_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+42; 663 int START_INSTRUMENTATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+43; 664 int FINISH_INSTRUMENTATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+44; 665 int GET_CONFIGURATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+45; 666 int UPDATE_CONFIGURATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+46; 667 int STOP_SERVICE_TOKEN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+47; 668 int GET_ACTIVITY_CLASS_FOR_TOKEN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+48; 669 int GET_PACKAGE_FOR_TOKEN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+49; 670 int SET_PROCESS_LIMIT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+50; 671 int GET_PROCESS_LIMIT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+51; 672 int CHECK_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+52; 673 int CHECK_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+53; 674 int GRANT_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+54; 675 int REVOKE_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+55; 676 int SET_ACTIVITY_CONTROLLER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+56; 677 int SHOW_WAITING_FOR_DEBUGGER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+57; 678 int SIGNAL_PERSISTENT_PROCESSES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+58; 679 int GET_RECENT_TASKS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+59; 680 int SERVICE_DONE_EXECUTING_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+60; 681 int ACTIVITY_DESTROYED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+61; 682 int GET_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+62; 683 int CANCEL_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+63; 684 int GET_PACKAGE_FOR_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+64; 685 int ENTER_SAFE_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+65; 686 int START_NEXT_MATCHING_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+66; 687 int NOTE_WAKEUP_ALARM_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+67; 688 int REMOVE_CONTENT_PROVIDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+68; 689 int SET_REQUESTED_ORIENTATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+69; 690 int GET_REQUESTED_ORIENTATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+70; 691 int UNBIND_FINISHED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+71; 692 int SET_PROCESS_FOREGROUND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+72; 693 int SET_SERVICE_FOREGROUND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+73; 694 int MOVE_ACTIVITY_TASK_TO_BACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+74; 695 int GET_MEMORY_INFO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+75; 696 int GET_PROCESSES_IN_ERROR_STATE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+76; 697 int CLEAR_APP_DATA_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+77; 698 int FORCE_STOP_PACKAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+78; 699 int KILL_PIDS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+79; 700 int GET_SERVICES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+80; 701 int GET_TASK_THUMBNAIL_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+81; 702 int GET_RUNNING_APP_PROCESSES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+82; 703 int GET_DEVICE_CONFIGURATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+83; 704 int PEEK_SERVICE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+84; 705 int PROFILE_CONTROL_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+85; 706 int SHUTDOWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+86; 707 int STOP_APP_SWITCHES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+87; 708 int RESUME_APP_SWITCHES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+88; 709 int START_BACKUP_AGENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+89; 710 int BACKUP_AGENT_CREATED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+90; 711 int UNBIND_BACKUP_AGENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+91; 712 int GET_UID_FOR_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+92; 713 int HANDLE_INCOMING_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+93; 714 int ADD_PACKAGE_DEPENDENCY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+94; 715 int KILL_APPLICATION_WITH_APPID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+95; 716 int CLOSE_SYSTEM_DIALOGS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+96; 717 int GET_PROCESS_MEMORY_INFO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+97; 718 int KILL_APPLICATION_PROCESS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+98; 719 int START_ACTIVITY_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+99; 720 int OVERRIDE_PENDING_TRANSITION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+100; 721 int HANDLE_APPLICATION_WTF_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+101; 722 int KILL_BACKGROUND_PROCESSES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+102; 723 int IS_USER_A_MONKEY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+103; 724 int START_ACTIVITY_AND_WAIT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+104; 725 int WILL_ACTIVITY_BE_VISIBLE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+105; 726 int START_ACTIVITY_WITH_CONFIG_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+106; 727 int GET_RUNNING_EXTERNAL_APPLICATIONS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+107; 728 int FINISH_HEAVY_WEIGHT_APP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+108; 729 int HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+109; 730 int IS_IMMERSIVE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+110; 731 int SET_IMMERSIVE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+111; 732 int IS_TOP_ACTIVITY_IMMERSIVE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+112; 733 int CRASH_APPLICATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+113; 734 int GET_PROVIDER_MIME_TYPE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+114; 735 int NEW_URI_PERMISSION_OWNER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+115; 736 int GRANT_URI_PERMISSION_FROM_OWNER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+116; 737 int REVOKE_URI_PERMISSION_FROM_OWNER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+117; 738 int CHECK_GRANT_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+118; 739 int DUMP_HEAP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+119; 740 int START_ACTIVITIES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+120; 741 int IS_USER_RUNNING_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+121; 742 int ACTIVITY_SLEPT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+122; 743 int GET_FRONT_ACTIVITY_SCREEN_COMPAT_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+123; 744 int SET_FRONT_ACTIVITY_SCREEN_COMPAT_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+124; 745 int GET_PACKAGE_SCREEN_COMPAT_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+125; 746 int SET_PACKAGE_SCREEN_COMPAT_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+126; 747 int GET_PACKAGE_ASK_SCREEN_COMPAT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+127; 748 int SET_PACKAGE_ASK_SCREEN_COMPAT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+128; 749 int SWITCH_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+129; 750 int ___AVAILABLE_1___ = IBinder.FIRST_CALL_TRANSACTION+130; 751 int REMOVE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+131; 752 int REGISTER_PROCESS_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+132; 753 int UNREGISTER_PROCESS_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+133; 754 int IS_INTENT_SENDER_TARGETED_TO_PACKAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+134; 755 int UPDATE_PERSISTENT_CONFIGURATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+135; 756 int GET_PROCESS_PSS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+136; 757 int SHOW_BOOT_MESSAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+137; 758 int KILL_ALL_BACKGROUND_PROCESSES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+139; 759 int GET_CONTENT_PROVIDER_EXTERNAL_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+140; 760 int REMOVE_CONTENT_PROVIDER_EXTERNAL_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+141; 761 int GET_MY_MEMORY_STATE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+142; 762 int KILL_PROCESSES_BELOW_FOREGROUND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+143; 763 int GET_CURRENT_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+144; 764 int SHOULD_UP_RECREATE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+145; 765 int NAVIGATE_UP_TO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+146; 766 int SET_LOCK_SCREEN_SHOWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+147; 767 int FINISH_ACTIVITY_AFFINITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+148; 768 int GET_LAUNCHED_FROM_UID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+149; 769 int UNSTABLE_PROVIDER_DIED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+150; 770 int IS_INTENT_SENDER_AN_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+151; 771 int START_ACTIVITY_AS_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+152; 772 int STOP_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+153; 773 int REGISTER_USER_SWITCH_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+154; 774 int UNREGISTER_USER_SWITCH_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+155; 775 int GET_RUNNING_USER_IDS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+156; 776 int REQUEST_BUG_REPORT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+157; 777 int INPUT_DISPATCHING_TIMED_OUT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+158; 778 int CLEAR_PENDING_BACKUP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+159; 779 int GET_INTENT_FOR_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+160; 780 int GET_ASSIST_CONTEXT_EXTRAS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+161; 781 int REPORT_ASSIST_CONTEXT_EXTRAS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+162; 782 int GET_LAUNCHED_FROM_PACKAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+163; 783 int KILL_UID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+164; 784 int SET_USER_IS_MONKEY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+165; 785 int HANG_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+166; 786 int CREATE_VIRTUAL_ACTIVITY_CONTAINER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+167; 787 int MOVE_TASK_TO_STACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+168; 788 int RESIZE_STACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+169; 789 int GET_ALL_STACK_INFOS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+170; 790 int SET_FOCUSED_STACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+171; 791 int GET_STACK_INFO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+172; 792 int CONVERT_FROM_TRANSLUCENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+173; 793 int CONVERT_TO_TRANSLUCENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+174; 794 int NOTIFY_ACTIVITY_DRAWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+175; 795 int REPORT_ACTIVITY_FULLY_DRAWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+176; 796 int RESTART_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+177; 797 int PERFORM_IDLE_MAINTENANCE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+178; 798 int TAKE_PERSISTABLE_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+179; 799 int RELEASE_PERSISTABLE_URI_PERMISSION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+180; 800 int GET_PERSISTED_URI_PERMISSIONS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+181; 801 int APP_NOT_RESPONDING_VIA_PROVIDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+182; 802 // Available 803 int GET_ACTIVITY_DISPLAY_ID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+184; 804 int DELETE_ACTIVITY_CONTAINER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+185; 805 int SET_PROCESS_MEMORY_TRIM_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+186; 806 807 808 // Start of L transactions 809 int GET_TAG_FOR_INTENT_SENDER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+210; 810 int START_USER_IN_BACKGROUND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+211; 811 int IS_IN_HOME_STACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+212; 812 int START_LOCK_TASK_BY_TASK_ID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+213; 813 int START_LOCK_TASK_BY_TOKEN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+214; 814 int STOP_LOCK_TASK_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+215; 815 int IS_IN_LOCK_TASK_MODE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+216; 816 int SET_TASK_DESCRIPTION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+217; 817 int START_VOICE_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+218; 818 int GET_ACTIVITY_OPTIONS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+219; 819 int GET_APP_TASKS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+220; 820 int START_LOCK_TASK_BY_CURRENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+221; 821 int STOP_LOCK_TASK_BY_CURRENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+222; 822 int FINISH_VOICE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+223; 823 int IS_TOP_OF_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+224; 824 int REQUEST_VISIBLE_BEHIND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+225; 825 int IS_BACKGROUND_VISIBLE_BEHIND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+226; 826 int BACKGROUND_RESOURCES_RELEASED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+227; 827 int NOTIFY_LAUNCH_TASK_BEHIND_COMPLETE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+228; 828 int START_ACTIVITY_FROM_RECENTS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION + 229; 829 int NOTIFY_ENTER_ANIMATION_COMPLETE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+230; 830 int KEYGUARD_WAITING_FOR_ACTIVITY_DRAWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+231; 831 int START_ACTIVITY_AS_CALLER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+232; 832 int ADD_APP_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+233; 833 int GET_APP_TASK_THUMBNAIL_SIZE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+234; 834 int RELEASE_ACTIVITY_INSTANCE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+235; 835 int RELEASE_SOME_ACTIVITIES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+236; 836 int BOOT_ANIMATION_COMPLETE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+237; 837 int GET_TASK_DESCRIPTION_ICON_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+238; 838 int LAUNCH_ASSIST_INTENT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+239; 839 int START_IN_PLACE_ANIMATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+240; 840 int CHECK_PERMISSION_WITH_TOKEN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+241; 841 int REGISTER_TASK_STACK_LISTENER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+242; 842 843 // Start of M transactions 844 int NOTIFY_CLEARTEXT_NETWORK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+280; 845 int CREATE_STACK_ON_DISPLAY = IBinder.FIRST_CALL_TRANSACTION+281; 846 int GET_FOCUSED_STACK_ID_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+282; 847 int SET_TASK_RESIZEABLE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+283; 848 int REQUEST_ASSIST_CONTEXT_EXTRAS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+284; 849 int RESIZE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+285; 850 int GET_LOCK_TASK_MODE_STATE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+286; 851 int SET_DUMP_HEAP_DEBUG_LIMIT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+287; 852 int DUMP_HEAP_FINISHED_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+288; 853 int SET_VOICE_KEEP_AWAKE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+289; 854 int UPDATE_LOCK_TASK_PACKAGES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+290; 855 int NOTE_ALARM_START_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+291; 856 int NOTE_ALARM_FINISH_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+292; 857 int GET_PACKAGE_PROCESS_STATE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+293; 858 int SHOW_LOCK_TASK_ESCAPE_MESSAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+294; 859 int UPDATE_DEVICE_OWNER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+295; 860 int KEYGUARD_GOING_AWAY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+296; 861 int REGISTER_UID_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+297; 862 int UNREGISTER_UID_OBSERVER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+298; 863 int IS_SCREEN_CAPTURE_ALLOWED_ON_CURRENT_ACTIVITY_TRANSACTION 864 = IBinder.FIRST_CALL_TRANSACTION+299; 865 int SHOW_ASSIST_FROM_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+300; 866 int IS_ROOT_VOICE_INTERACTION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+301; 867 } 868