blob: b8af8989170e364d7a5803b114caf4d85bcf5ee2 [file] [log] [blame]
Sudheer Shankacc6418f2016-10-13 12:03:44 -07001/*
2 * Copyright (C) 2016 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
17package android.app;
18
19import android.app.IInstrumentationWatcher;
20import android.app.IUiAutomationConnection;
21import android.app.ProfilerInfo;
22import android.app.ResultInfo;
Andrii Kulian446e8242017-10-26 15:17:29 -070023import android.app.servertransaction.ClientTransaction;
Felipe Lemea4f39cd2019-02-19 15:08:59 -080024import android.content.AutofillOptions;
Sudheer Shankacc6418f2016-10-13 12:03:44 -070025import android.content.ComponentName;
Felipe Leme326f15a2019-02-19 09:42:24 -080026import android.content.ContentCaptureOptions;
Sudheer Shankacc6418f2016-10-13 12:03:44 -070027import android.content.IIntentReceiver;
28import android.content.Intent;
29import android.content.pm.ActivityInfo;
30import android.content.pm.ApplicationInfo;
Dianne Hackborn3f7c9f22017-04-04 15:36:33 -070031import android.content.pm.ParceledListSlice;
Sudheer Shankacc6418f2016-10-13 12:03:44 -070032import android.content.pm.ProviderInfo;
33import android.content.pm.ServiceInfo;
34import android.content.res.CompatibilityInfo;
35import android.content.res.Configuration;
36import android.net.Uri;
37import android.os.Bundle;
38import android.os.Debug;
39import android.os.IBinder;
40import android.os.IInterface;
41import android.os.ParcelFileDescriptor;
42import android.os.PersistableBundle;
Makoto Onuki2c6657f2018-06-06 15:24:02 -070043import android.os.RemoteCallback;
Sudheer Shankacc6418f2016-10-13 12:03:44 -070044
45import com.android.internal.app.IVoiceInteractor;
46import com.android.internal.content.ReferrerIntent;
47
48import java.util.List;
49import java.util.Map;
50
51/**
52 * System private API for communicating with the application. This is given to
53 * the activity manager by an application when it starts up, for the activity
54 * manager to tell the application about things it needs to do.
55 *
56 * {@hide}
57 */
58oneway interface IApplicationThread {
Sudheer Shankacc6418f2016-10-13 12:03:44 -070059 void scheduleReceiver(in Intent intent, in ActivityInfo info,
60 in CompatibilityInfo compatInfo,
61 int resultCode, in String data, in Bundle extras, boolean sync,
Sudheer Shanka3052f852016-11-14 18:42:20 -080062 int sendingUser, int processState);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070063 void scheduleCreateService(IBinder token, in ServiceInfo info,
Sudheer Shanka3052f852016-11-14 18:42:20 -080064 in CompatibilityInfo compatInfo, int processState);
65 void scheduleStopService(IBinder token);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070066 void bindApplication(in String packageName, in ApplicationInfo info,
67 in List<ProviderInfo> providers, in ComponentName testName,
68 in ProfilerInfo profilerInfo, in Bundle testArguments,
69 IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection,
70 int debugMode, boolean enableBinderTracking, boolean trackAllocation,
71 boolean restrictedBackupMode, boolean persistent, in Configuration config,
72 in CompatibilityInfo compatInfo, in Map services,
Felipe Lemea4f39cd2019-02-19 15:08:59 -080073 in Bundle coreSettings, in String buildSerial, in AutofillOptions autofillOptions,
Felipe Leme326f15a2019-02-19 09:42:24 -080074 in ContentCaptureOptions contentCaptureOptions);
Torne (Richard Coles)466cbe42017-05-31 14:09:14 -040075 void runIsolatedEntryPoint(in String entryPoint, in String[] entryPointArgs);
Sudheer Shanka3052f852016-11-14 18:42:20 -080076 void scheduleExit();
Dianne Hackborn3f7c9f22017-04-04 15:36:33 -070077 void scheduleServiceArgs(IBinder token, in ParceledListSlice args);
Sudheer Shanka3052f852016-11-14 18:42:20 -080078 void updateTimeZone();
79 void processInBackground();
Sudheer Shankacc6418f2016-10-13 12:03:44 -070080 void scheduleBindService(IBinder token,
Sudheer Shanka3052f852016-11-14 18:42:20 -080081 in Intent intent, boolean rebind, int processState);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070082 void scheduleUnbindService(IBinder token,
Sudheer Shanka3052f852016-11-14 18:42:20 -080083 in Intent intent);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070084 void dumpService(in ParcelFileDescriptor fd, IBinder servicetoken,
Sudheer Shanka3052f852016-11-14 18:42:20 -080085 in String[] args);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070086 void scheduleRegisteredReceiver(IIntentReceiver receiver, in Intent intent,
87 int resultCode, in String data, in Bundle extras, boolean ordered,
Sudheer Shanka3052f852016-11-14 18:42:20 -080088 boolean sticky, int sendingUser, int processState);
89 void scheduleLowMemory();
Sudheer Shanka3052f852016-11-14 18:42:20 -080090 void scheduleSleeping(IBinder token, boolean sleeping);
91 void profilerControl(boolean start, in ProfilerInfo profilerInfo, int profileType);
92 void setSchedulingGroup(int group);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070093 void scheduleCreateBackupAgent(in ApplicationInfo app, in CompatibilityInfo compatInfo,
Ruslan Tkhakokhov063180f2019-01-28 20:29:46 +000094 int backupMode, int userId);
Sudheer Shankacc6418f2016-10-13 12:03:44 -070095 void scheduleDestroyBackupAgent(in ApplicationInfo app,
Annie Mengd5827872019-01-30 20:28:57 +000096 in CompatibilityInfo compatInfo, int userId);
Sudheer Shanka3052f852016-11-14 18:42:20 -080097 void scheduleOnNewActivityOptions(IBinder token, in Bundle options);
98 void scheduleSuicide();
99 void dispatchPackageBroadcast(int cmd, in String[] packages);
100 void scheduleCrash(in String msg);
Christopher Ferris8d652f82017-04-11 16:29:18 -0700101 void dumpHeap(boolean managed, boolean mallocInfo, boolean runGc, in String path,
Makoto Onuki2c6657f2018-06-06 15:24:02 -0700102 in ParcelFileDescriptor fd, in RemoteCallback finishCallback);
Sudheer Shankacc6418f2016-10-13 12:03:44 -0700103 void dumpActivity(in ParcelFileDescriptor fd, IBinder servicetoken, in String prefix,
Sudheer Shanka3052f852016-11-14 18:42:20 -0800104 in String[] args);
105 void clearDnsCache();
Irina Dumitrescu18622d32018-12-05 16:19:47 +0000106 void updateHttpProxy();
Sudheer Shanka3052f852016-11-14 18:42:20 -0800107 void setCoreSettings(in Bundle coreSettings);
108 void updatePackageCompatibilityInfo(in String pkg, in CompatibilityInfo info);
109 void scheduleTrimMemory(int level);
Sudheer Shankacc6418f2016-10-13 12:03:44 -0700110 void dumpMemInfo(in ParcelFileDescriptor fd, in Debug.MemoryInfo mem, boolean checkin,
111 boolean dumpInfo, boolean dumpDalvik, boolean dumpSummaryOnly, boolean dumpUnreachable,
Sudheer Shanka3052f852016-11-14 18:42:20 -0800112 in String[] args);
Kweku Adams983829f2017-12-06 14:53:50 -0800113 void dumpMemInfoProto(in ParcelFileDescriptor fd, in Debug.MemoryInfo mem,
114 boolean dumpInfo, boolean dumpDalvik, boolean dumpSummaryOnly, boolean dumpUnreachable,
115 in String[] args);
Sudheer Shanka3052f852016-11-14 18:42:20 -0800116 void dumpGfxInfo(in ParcelFileDescriptor fd, in String[] args);
Sudheer Shankacc6418f2016-10-13 12:03:44 -0700117 void dumpProvider(in ParcelFileDescriptor fd, IBinder servicetoken,
Sudheer Shanka3052f852016-11-14 18:42:20 -0800118 in String[] args);
119 void dumpDbInfo(in ParcelFileDescriptor fd, in String[] args);
120 void unstableProviderDied(IBinder provider);
Sudheer Shankacc6418f2016-10-13 12:03:44 -0700121 void requestAssistContextExtras(IBinder activityToken, IBinder requestToken,
Svet Ganovfd31f852017-04-26 15:54:27 -0700122 int requestType, int sessionId, int flags);
Sudheer Shanka3052f852016-11-14 18:42:20 -0800123 void scheduleTranslucentConversionComplete(IBinder token, boolean timeout);
124 void setProcessState(int state);
125 void scheduleInstallProvider(in ProviderInfo provider);
Neil Fullerb7146fe2016-11-15 16:52:15 +0000126 void updateTimePrefs(int timeFormatPreference);
Sudheer Shanka3052f852016-11-14 18:42:20 -0800127 void scheduleEnterAnimationComplete(IBinder token);
128 void notifyCleartextNetwork(in byte[] firstPacket);
129 void startBinderTracking();
130 void stopBinderTrackingAndDump(in ParcelFileDescriptor fd);
Sudheer Shankacc6418f2016-10-13 12:03:44 -0700131 void scheduleLocalVoiceInteractionStarted(IBinder token,
Sudheer Shanka3052f852016-11-14 18:42:20 -0800132 IVoiceInteractor voiceInteractor);
133 void handleTrustStorageUpdate();
134 void attachAgent(String path);
MÃ¥rten Kongstad49a4a1d2017-01-12 08:36:37 +0100135 void scheduleApplicationInfoChanged(in ApplicationInfo ai);
Sudheer Shanka84a48952017-03-08 18:19:01 -0800136 void setNetworkBlockSeq(long procStateSeq);
Andrii Kulian446e8242017-10-26 15:17:29 -0700137 void scheduleTransaction(in ClientTransaction transaction);
Neil Fullerb7146fe2016-11-15 16:52:15 +0000138}