Home
last modified time | relevance | path

Searched refs:PackageInstaller (Results 1 – 25 of 42) sorted by relevance

12

/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/wear/
DPackageInstallerImpl.java26 import android.content.pm.PackageInstaller;
50 private final PackageInstaller mPackageInstaller;
51 private final Map<String, PackageInstaller.SessionInfo> mSessionInfoMap;
52 private final Map<String, PackageInstaller.Session> mOpenSessionMap;
60 mSessionInfoMap = new HashMap<String, PackageInstaller.SessionInfo>(); in PackageInstallerImpl()
61 List<PackageInstaller.SessionInfo> mySessions = mPackageInstaller.getMySessions(); in PackageInstallerImpl()
63 PackageInstaller.SessionInfo sessionInfo = mySessions.get(i); in PackageInstallerImpl()
65 PackageInstaller.SessionInfo oldInfo = mSessionInfoMap.put(packageName, sessionInfo); in PackageInstallerImpl()
73 mOpenSessionMap = new HashMap<String, PackageInstaller.Session>(); in PackageInstallerImpl()
112 PackageInstaller.Session session = null; in install()
[all …]
DInstallTask.java21 import android.content.pm.PackageInstaller;
45 private PackageInstaller.Session mSession;
54 PackageInstallerImpl.InstallListener callback, PackageInstaller.Session session, in InstallTask()
/frameworks/base/tests/RollbackTest/RollbackTest/src/com/android/tests/rollback/
DRollbackTestUtils.java33 import android.content.pm.PackageInstaller;
115 int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in assertStatusSuccess()
116 PackageInstaller.STATUS_FAILURE); in assertStatusSuccess()
120 String message = result.getStringExtra(PackageInstaller.EXTRA_STATUS_MESSAGE); in assertStatusSuccess()
138 PackageInstaller packageInstaller = packageManager.getPackageInstaller(); in uninstall()
185 PackageInstaller.Session session = null; in installSplit()
186 PackageInstaller packageInstaller = context.getPackageManager().getPackageInstaller(); in installSplit()
187 PackageInstaller.SessionParams params = new PackageInstaller.SessionParams( in installSplit()
188 PackageInstaller.SessionParams.MODE_FULL_INSTALL); in installSplit()
238 PackageInstaller packageInstaller = context.getPackageManager().getPackageInstaller(); in install()
[all …]
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/
DInstallInstalling.java19 import static android.content.pm.PackageInstaller.SessionParams.UID_UNKNOWN;
26 import android.content.pm.PackageInstaller;
62 private PackageInstaller.SessionCallback mSessionCallback;
131 PackageInstaller.SessionParams params = new PackageInstaller.SessionParams( in onCreate()
132 PackageInstaller.SessionParams.MODE_FULL_INSTALL); in onCreate()
204 failureIntent.putExtra(PackageInstaller.EXTRA_LEGACY_STATUS, legacyStatus); in launchFailure()
205 failureIntent.putExtra(PackageInstaller.EXTRA_STATUS_MESSAGE, statusMessage); in launchFailure()
224 PackageInstaller installer = getPackageManager().getPackageInstaller(); in onResume()
225 PackageInstaller.SessionInfo sessionInfo = installer.getSessionInfo(mSessionId); in onResume()
289 if (statusCode == PackageInstaller.STATUS_SUCCESS) { in launchFinishBasedOnResult()
[all …]
DInstallFailed.java28 import android.content.pm.PackageInstaller;
58 case PackageInstaller.STATUS_FAILURE_BLOCKED: in setExplanationFromErrorCode()
61 case PackageInstaller.STATUS_FAILURE_CONFLICT: in setExplanationFromErrorCode()
64 case PackageInstaller.STATUS_FAILURE_INCOMPATIBLE: in setExplanationFromErrorCode()
67 case PackageInstaller.STATUS_FAILURE_INVALID: in setExplanationFromErrorCode()
82 int statusCode = getIntent().getIntExtra(PackageInstaller.EXTRA_STATUS, in onCreate()
83 PackageInstaller.STATUS_FAILURE); in onCreate()
86 int legacyStatus = getIntent().getIntExtra(PackageInstaller.EXTRA_LEGACY_STATUS, in onCreate()
123 if (statusCode == PackageInstaller.STATUS_FAILURE_STORAGE) { in onCreate()
DInstallStart.java30 import android.content.pm.PackageInstaller;
58 PackageInstaller.ACTION_CONFIRM_INSTALL.equals(intent.getAction()); in onCreate()
63 ? intent.getIntExtra(PackageInstaller.EXTRA_SESSION_ID, -1) in onCreate()
66 PackageInstaller packageInstaller = getPackageManager().getPackageInstaller(); in onCreate()
67 PackageInstaller.SessionInfo sessionInfo = packageInstaller.getSessionInfo(sessionId); in onCreate()
79 if (!isTrustedSource && originatingUid != PackageInstaller.SessionParams.UID_UNKNOWN) { in onCreate()
184 PackageInstaller.SessionParams.UID_UNKNOWN); in getOriginatingUid()
197 return PackageInstaller.SessionParams.UID_UNKNOWN; in getOriginatingUid()
DUninstallUninstalling.java31 import android.content.pm.PackageInstaller;
68 mCallback = getIntent().getIBinderExtra(PackageInstaller.EXTRA_CALLBACK); in onCreate()
118 onResult(PackageInstaller.STATUS_FAILURE, PackageManager.DELETE_FAILED_INTERNAL_ERROR, in onCreate()
150 setResult(status == PackageInstaller.STATUS_SUCCESS ? Activity.RESULT_OK in onResult()
155 if (status != PackageInstaller.STATUS_SUCCESS) { in onResult()
DUninstallFinish.java30 import android.content.pm.PackageInstaller;
57 int returnCode = intent.getIntExtra(PackageInstaller.EXTRA_STATUS, 0); in onReceive()
61 if (returnCode == PackageInstaller.STATUS_PENDING_USER_ACTION) { in onReceive()
86 case PackageInstaller.STATUS_SUCCESS: in onReceive()
92 case PackageInstaller.STATUS_FAILURE_BLOCKED: { in onReceive()
93 int legacyStatus = intent.getIntExtra(PackageInstaller.EXTRA_LEGACY_STATUS, 0); in onReceive()
DEventResultPersister.java23 import android.content.pm.PackageInstaller;
182 int status = intent.getIntExtra(PackageInstaller.EXTRA_STATUS, 0); in onEventReceived()
184 if (status == PackageInstaller.STATUS_PENDING_USER_ACTION) { in onEventReceived()
191 String statusMessage = intent.getStringExtra(PackageInstaller.EXTRA_STATUS_MESSAGE); in onEventReceived()
192 int legacyStatus = intent.getIntExtra(PackageInstaller.EXTRA_LEGACY_STATUS, 0); in onEventReceived()
DPackageInstallerActivity.java38 import android.content.pm.PackageInstaller;
82 private int mOriginatingUid = PackageInstaller.SessionParams.UID_UNKNOWN;
90 PackageInstaller mInstaller;
303 PackageInstaller.SessionParams.UID_UNKNOWN); in onCreate()
304 mOriginatingPackage = (mOriginatingUid != PackageInstaller.SessionParams.UID_UNKNOWN) in onCreate()
310 if (PackageInstaller.ACTION_CONFIRM_INSTALL.equals(intent.getAction())) { in onCreate()
311 final int sessionId = intent.getIntExtra(PackageInstaller.EXTRA_SESSION_ID, -1); in onCreate()
312 final PackageInstaller.SessionInfo info = mInstaller.getSessionInfo(sessionId); in onCreate()
570 if (mOriginatingUid != PackageInstaller.SessionParams.UID_UNKNOWN) { in startInstall()
DUninstallerActivity.java45 import android.content.pm.PackageInstaller;
182 mDialogInfo.callback = intent.getIBinderExtra(PackageInstaller.EXTRA_CALLBACK); in onCreate()
296 newIntent.putExtra(PackageInstaller.EXTRA_CALLBACK, mDialogInfo.callback); in startUninstallProgress()
314 newIntent.putExtra(PackageInstaller.EXTRA_CALLBACK, mDialogInfo.callback); in startUninstallProgress()
/frameworks/base/core/java/android/content/pm/
DPackageManager.java6833 public abstract @NonNull PackageInstaller getPackageInstaller(); in getPackageInstaller()
6951 case INSTALL_SUCCEEDED: return PackageInstaller.STATUS_SUCCESS; in installStatusToPublicStatus()
6952 case INSTALL_FAILED_ALREADY_EXISTS: return PackageInstaller.STATUS_FAILURE_CONFLICT; in installStatusToPublicStatus()
6953 case INSTALL_FAILED_INVALID_APK: return PackageInstaller.STATUS_FAILURE_INVALID; in installStatusToPublicStatus()
6954 case INSTALL_FAILED_INVALID_URI: return PackageInstaller.STATUS_FAILURE_INVALID; in installStatusToPublicStatus()
6955 … case INSTALL_FAILED_INSUFFICIENT_STORAGE: return PackageInstaller.STATUS_FAILURE_STORAGE; in installStatusToPublicStatus()
6956 case INSTALL_FAILED_DUPLICATE_PACKAGE: return PackageInstaller.STATUS_FAILURE_CONFLICT; in installStatusToPublicStatus()
6957 case INSTALL_FAILED_NO_SHARED_USER: return PackageInstaller.STATUS_FAILURE_CONFLICT; in installStatusToPublicStatus()
6958 … case INSTALL_FAILED_UPDATE_INCOMPATIBLE: return PackageInstaller.STATUS_FAILURE_CONFLICT; in installStatusToPublicStatus()
6959 … case INSTALL_FAILED_SHARED_USER_INCOMPATIBLE: return PackageInstaller.STATUS_FAILURE_CONFLICT; in installStatusToPublicStatus()
[all …]
DPackageInstaller.aidl19 parcelable PackageInstaller.SessionParams;
20 parcelable PackageInstaller.SessionInfo;
DIPackageInstaller.aidl22 import android.content.pm.PackageInstaller;
31 …int createSession(in PackageInstaller.SessionParams params, String installerPackageName, int userI… in createSession()
40 PackageInstaller.SessionInfo getSessionInfo(int sessionId); in getSessionInfo()
DILauncherApps.aidl28 import android.content.pm.PackageInstaller;
50 in PackageInstaller.SessionInfo sessionInfo, in Rect sourceBounds, in Bundle opts, in startSessionDetailsActivityAsUser()
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/
DPackageInstallerSessionTest.java26 import android.content.pm.PackageInstaller;
115 return createSession(false, false, 123, false, PackageInstaller.SessionInfo.INVALID_ID, in createSimpleSession()
120 return createSession(true, false, 123, false, PackageInstaller.SessionInfo.INVALID_ID, in createStagedSession()
125 return createSession(false, true, 123, false, PackageInstaller.SessionInfo.INVALID_ID, in createSessionWithGrantedPermissions()
132 PackageInstaller.SessionInfo.INVALID_ID, childSessionIds); in createMultiPackageParentSession()
143 PackageInstaller.SessionParams params = new PackageInstaller.SessionParams( in createSession()
144 PackageInstaller.SessionParams.MODE_FULL_INSTALL); in createSession()
178 PackageInstaller.SessionInfo.STAGED_SESSION_VERIFICATION_FAILED, in createSession()
250 private void assertSessionParamsEquivalent(PackageInstaller.SessionParams expected, in assertSessionParamsEquivalent()
251 PackageInstaller.SessionParams actual) { in assertSessionParamsEquivalent()
/frameworks/base/services/backup/java/com/android/server/backup/utils/
DRestoreUtils.java29 import android.content.pm.PackageInstaller;
30 import android.content.pm.PackageInstaller.Session;
31 import android.content.pm.PackageInstaller.SessionParams;
87 PackageInstaller installer = packageManager.getPackageInstaller(); in installApk()
124 int status = PackageInstaller.STATUS_FAILURE; in installApk()
128 if (status != PackageInstaller.STATUS_SUCCESS) { in installApk()
139 PackageInstaller.EXTRA_PACKAGE_NAME); in installApk()
/frameworks/base/services/core/java/com/android/server/rollback/
DRollbackManagerServiceImpl.java31 import android.content.pm.PackageInstaller;
418 PackageInstaller packageInstaller = pm.getPackageInstaller(); in commitRollbackInternal()
419 PackageInstaller.SessionParams parentParams = new PackageInstaller.SessionParams( in commitRollbackInternal()
420 PackageInstaller.SessionParams.MODE_FULL_INSTALL); in commitRollbackInternal()
428 PackageInstaller.Session parentSession = packageInstaller.openSession(parentSessionId); in commitRollbackInternal()
431 PackageInstaller.SessionParams params = new PackageInstaller.SessionParams( in commitRollbackInternal()
432 PackageInstaller.SessionParams.MODE_FULL_INSTALL); in commitRollbackInternal()
452 PackageInstaller.Session session = packageInstaller.openSession(sessionId); in commitRollbackInternal()
481 int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in commitRollbackInternal()
482 PackageInstaller.STATUS_FAILURE); in commitRollbackInternal()
[all …]
DRollbackPackageHealthObserver.java24 import android.content.pm.PackageInstaller;
177 PackageInstaller packageInstaller = mContext.getPackageManager().getPackageInstaller(); in onBootCompleted()
215 PackageInstaller.SessionInfo sessionInfo = packageInstaller.getSessionInfo(sessionId); in onBootCompleted()
283 new IntentFilter(PackageInstaller.ACTION_SESSION_UPDATED); in listenForStagedSessionReady()
290 PackageInstaller packageInstaller = in handleStagedSessionChange()
298 && (sessionId != PackageInstaller.SessionInfo.INVALID_ID)) { in handleStagedSessionChange()
299 PackageInstaller.SessionInfo sessionInfo = in handleStagedSessionChange()
/frameworks/base/services/core/java/com/android/server/pm/
DStagingManager.java30 import android.content.pm.PackageInstaller;
31 import android.content.pm.PackageInstaller.SessionInfo;
97 ParceledListSlice<PackageInstaller.SessionInfo> getSessions() { in getSessions()
98 final List<PackageInstaller.SessionInfo> result = new ArrayList<>(); in getSessions()
396 PackageInstaller.SessionParams params = originalSession.params.copy(); in createAndWriteApkSession()
451 final int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in commitApkSession()
452 PackageInstaller.STATUS_FAILURE); in commitApkSession()
453 if (status == PackageInstaller.STATUS_SUCCESS) { in commitApkSession()
457 + result.getStringExtra(PackageInstaller.EXTRA_STATUS_MESSAGE) + "]"); in commitApkSession()
489 PackageInstaller.SessionParams params = session.params.copy(); in installApksInSession()
DPackageInstallerService.java41 import android.content.pm.PackageInstaller;
42 import android.content.pm.PackageInstaller.SessionInfo;
43 import android.content.pm.PackageInstaller.SessionParams;
852 intent.putExtra(PackageInstaller.EXTRA_CALLBACK, adapter.getBinder().asBinder()); in uninstall()
951 fillIn.putExtra(PackageInstaller.EXTRA_PACKAGE_NAME, mPackageName); in onUserActionRequired()
952 fillIn.putExtra(PackageInstaller.EXTRA_STATUS, in onUserActionRequired()
953 PackageInstaller.STATUS_PENDING_USER_ACTION); in onUserActionRequired()
974 fillIn.putExtra(PackageInstaller.EXTRA_PACKAGE_NAME, mPackageName); in onPackageDeleted()
975 fillIn.putExtra(PackageInstaller.EXTRA_STATUS, in onPackageDeleted()
977 fillIn.putExtra(PackageInstaller.EXTRA_STATUS_MESSAGE, in onPackageDeleted()
[all …]
DPackageManagerShellCommand.java44 import android.content.pm.PackageInstaller;
45 import android.content.pm.PackageInstaller.SessionInfo;
46 import android.content.pm.PackageInstaller.SessionParams;
384 final int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in uninstallSystemUpdates()
385 PackageInstaller.STATUS_FAILURE); in uninstallSystemUpdates()
386 if (status != PackageInstaller.STATUS_SUCCESS) { in uninstallSystemUpdates()
1073 false /*logSuccess*/) != PackageInstaller.STATUS_SUCCESS) { in runInstall()
1077 != PackageInstaller.STATUS_SUCCESS) { in runInstall()
1209 final int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in runInstallExisting()
1210 PackageInstaller.STATUS_FAILURE); in runInstallExisting()
[all …]
DPackageInstallerSession.java58 import android.content.pm.PackageInstaller;
59 import android.content.pm.PackageInstaller.SessionInfo;
60 import android.content.pm.PackageInstaller.SessionInfo.StagedSessionErrorCode;
61 import android.content.pm.PackageInstaller.SessionParams;
688 if (PackageInstaller.ENABLE_REVOCABLE_FD) { in doWriteInternal()
763 if (PackageInstaller.ENABLE_REVOCABLE_FD) { in doWriteInternal()
772 } else if (PackageInstaller.ENABLE_REVOCABLE_FD) { in doWriteInternal()
909 PackageInstaller.EXTRA_SESSION_ID, 0); in statusUpdate()
910 final int status = intent.getIntExtra(PackageInstaller.EXTRA_STATUS, in statusUpdate()
911 PackageInstaller.STATUS_FAILURE); in statusUpdate()
[all …]
/frameworks/base/core/tests/coretests/src/android/content/pm/
DPackageManagerTests.java35 import android.content.pm.PackageInstaller.SessionParams;
199 private PackageInstaller getPi() { in getPi()
203 private void writeSplitToInstallSession(PackageInstaller.Session session, String inPath, in writeSplitToInstallSession()
241 PackageInstaller.Session session = null; in invokeInstallPackage()
252 final int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in invokeInstallPackage()
253 PackageInstaller.STATUS_FAILURE); in invokeInstallPackage()
255 if (status != PackageInstaller.STATUS_SUCCESS) { in invokeInstallPackage()
259 if (status == PackageInstaller.STATUS_SUCCESS) { in invokeInstallPackage()
290 PackageInstaller.Session session = null; in invokeInstallPackageFail()
301 final int status = result.getIntExtra(PackageInstaller.EXTRA_STATUS, in invokeInstallPackageFail()
[all …]
/frameworks/base/packages/PackageInstaller/
DAndroid.bp16 name: "PackageInstaller",

12