/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | CarrierAppUtilsTest.java | 21 import android.content.pm.PackageManager; 85 PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS, USER_ID)).thenReturn(null); in testDisableCarrierAppsUntilPrivileged_MissingApp() 103 PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS, USER_ID)).thenReturn(appInfo); in testDisableCarrierAppsUntilPrivileged_NonSystemApp() 125 appInfo.enabledSetting = PackageManager.COMPONENT_ENABLED_STATE_DISABLED_USER; in testDisableCarrierAppsUntilPrivileged_HasPrivileges_DisabledUser() 127 PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS, USER_ID)).thenReturn(appInfo); in testDisableCarrierAppsUntilPrivileged_HasPrivileges_DisabledUser() 145 appInfo.enabledSetting = PackageManager.COMPONENT_ENABLED_STATE_DISABLED; in testDisableCarrierAppsUntilPrivileged_HasPrivileges_Disabled() 147 PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS, USER_ID)).thenReturn(appInfo); in testDisableCarrierAppsUntilPrivileged_HasPrivileges_Disabled() 165 appInfo.enabledSetting = PackageManager.COMPONENT_ENABLED_STATE_ENABLED; in testDisableCarrierAppsUntilPrivileged_HasPrivileges_Enabled() 167 PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS, USER_ID)).thenReturn(appInfo); in testDisableCarrierAppsUntilPrivileged_HasPrivileges_Enabled() 185 appInfo.enabledSetting = PackageManager.COMPONENT_ENABLED_STATE_ENABLED; in testDisableCarrierAppsUntilPrivileged_HasPrivileges_UpdatedApp() [all …]
|
/frameworks/base/core/tests/coretests/src/android/content/pm/ |
D | ComponentTest.java | 19 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DEFAULT; 20 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DISABLED; 21 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_ENABLED; 22 import static android.content.pm.PackageManager.GET_DISABLED_COMPONENTS; 52 private PackageManager mPackageManager; 135 PackageManager.DONT_KILL_APP); in testResolveDisabledActivity() 151 PackageManager.DONT_KILL_APP); in testResolveEnabledActivity() 164 PackageManager.DONT_KILL_APP); in testQueryDisabledActivity() 184 PackageManager.DONT_KILL_APP); in testQueryEnabledActivity() 199 PackageManager.DONT_KILL_APP); in testGetDisabledActivityInfo() [all …]
|
D | PackageManagerTests.java | 36 import android.content.pm.PackageManager.NameNotFoundException; 224 private PackageManager getPm() { in getPm() 397 if ((flags & PackageManager.INSTALL_EXTERNAL) != 0) { in getInstallLoc() 399 } else if ((flags & PackageManager.INSTALL_INTERNAL) != 0) { in getInstallLoc() 639 final PackageManager pm = getPm(); in assertPermissions() 650 PackageManager.GET_PERMISSIONS in assertPermissions() 651 | PackageManager.MATCH_UNINSTALLED_PACKAGES); in assertPermissions() 706 if (pm.checkPermission(cmd, pkg) != PackageManager.PERMISSION_GRANTED) { in assertPermissions() 710 if (pm.checkPermission(cmd, pkg) != PackageManager.PERMISSION_DENIED) { in assertPermissions() 721 PackageManager pm = mContext.getPackageManager(); in getParsedPackage() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | PackageVerificationStateTest.java | 19 import android.content.pm.PackageManager; 37 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_OnlyRequiredVerifier_AllowedInstall() 52 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_REJECT); in testPackageVerificationState_OnlyRequiredVerifier_DeniedInstall() 72 state.setVerifierResponse(SUFFICIENT_UID_1, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_RequiredAndOneSufficient_RequiredDeniedInstall() 77 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_REJECT); in testPackageVerificationState_RequiredAndOneSufficient_RequiredDeniedInstall() 97 state.setVerifierResponse(SUFFICIENT_UID_1, PackageManager.VERIFICATION_REJECT); in testPackageVerificationState_RequiredAndOneSufficient_SufficientDeniedInstall() 102 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_RequiredAndOneSufficient_SufficientDeniedInstall() 123 state.setVerifierResponse(SUFFICIENT_UID_1, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_RequiredAndTwoSufficient_OneSufficientIsEnough() 128 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_RequiredAndTwoSufficient_OneSufficientIsEnough() 149 state.setVerifierResponse(REQUIRED_UID, PackageManager.VERIFICATION_ALLOW); in testPackageVerificationState_RequiredAndTwoSufficient_SecondSufficientIsEnough() [all …]
|
D | PackageManagerPresubmitTest.java | 21 import android.content.pm.PackageManager; 39 import static android.content.pm.PackageManager.GET_PERMISSIONS; 51 private PackageManager mPackageManager; 67 public void testPrivAppPermissions() throws PackageManager.NameNotFoundException { in testPrivAppPermissions() 69 .getInstalledPackages(PackageManager.MATCH_UNINSTALLED_PACKAGES | GET_PERMISSIONS); in testPrivAppPermissions() 81 throws PackageManager.NameNotFoundException { in testPackagePrivAppPermission() 97 } catch (PackageManager.NameNotFoundException e) { in testPackagePrivAppPermission()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/ |
D | PreviewInflater.java | 23 import android.content.pm.PackageManager; 85 } catch (PackageManager.NameNotFoundException|RuntimeException e) { in inflateWidgetView() 92 PackageManager packageManager = mContext.getPackageManager(); in getWidgetInfoFromService() 96 componentName, PackageManager.GET_META_DATA).metaData; in getWidgetInfoFromService() 98 } catch (PackageManager.NameNotFoundException e) { in getWidgetInfoFromService() 121 PackageManager packageManager = mContext.getPackageManager(); in getWidgetInfo() 122 int flags = PackageManager.MATCH_DEFAULT_ONLY in getWidgetInfo() 123 | PackageManager.MATCH_DIRECT_BOOT_AWARE in getWidgetInfo() 124 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE; in getWidgetInfo() 131 flags | PackageManager.GET_META_DATA, in getWidgetInfo() [all …]
|
/frameworks/base/core/java/android/content/pm/ |
D | PackageUserState.java | 19 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DEFAULT; 20 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DISABLED; 21 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DISABLED_UNTIL_USED; 22 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DISABLED_USER; 23 import static android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_ENABLED; 24 import static android.content.pm.PackageManager.MATCH_DIRECT_BOOT_AWARE; 25 import static android.content.pm.PackageManager.MATCH_DIRECT_BOOT_UNAWARE; 26 import static android.content.pm.PackageManager.MATCH_DISABLED_COMPONENTS; 27 import static android.content.pm.PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS; 28 import static android.content.pm.PackageManager.MATCH_SYSTEM_ONLY; [all …]
|
D | PackageInstaller.java | 30 import android.content.pm.PackageManager.DeleteFlags; 31 import android.content.pm.PackageManager.InstallReason; 464 uninstall(new VersionedPackage(packageName, PackageManager.VERSION_CODE_HIGHEST), in uninstall() 976 throws PackageManager.NameNotFoundException { in transfer() 982 e.maybeRethrow(PackageManager.NameNotFoundException.class); in transfer() 1052 public @InstallReason int installReason = PackageManager.INSTALL_REASON_UNKNOWN; 1116 return (installFlags & (PackageManager.INSTALL_ALLOW_DOWNGRADE in areHiddenOptionsSet() 1117 | PackageManager.INSTALL_DONT_KILL_APP in areHiddenOptionsSet() 1118 | PackageManager.INSTALL_INSTANT_APP in areHiddenOptionsSet() 1119 | PackageManager.INSTALL_FULL_APP in areHiddenOptionsSet() [all …]
|
D | AppsQueryHelper.java | 172 PackageManager.MATCH_UNINSTALLED_PACKAGES in getAllApps() 173 | PackageManager.MATCH_DISABLED_COMPONENTS, userId).getList(); in getAllApps() 183 PackageManager.MATCH_DISABLED_COMPONENTS in queryIntentActivitiesAsUser() 184 | PackageManager.MATCH_UNINSTALLED_PACKAGES in queryIntentActivitiesAsUser() 185 | PackageManager.MATCH_DIRECT_BOOT_AWARE in queryIntentActivitiesAsUser() 186 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE, in queryIntentActivitiesAsUser() 197 PackageManager.GET_META_DATA in queryIntentServicesAsUser() 198 | PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS in queryIntentServicesAsUser() 199 | PackageManager.MATCH_DIRECT_BOOT_AWARE in queryIntentServicesAsUser() 200 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE, userId) in queryIntentServicesAsUser()
|
D | PackageItemInfo.java | 133 public CharSequence loadLabel(PackageManager pm) { in loadLabel() 166 public @NonNull CharSequence loadSafeLabel(@NonNull PackageManager pm) { in loadSafeLabel() 223 public Drawable loadIcon(PackageManager pm) { in loadIcon() 240 public Drawable loadUnbadgedIcon(PackageManager pm) { in loadUnbadgedIcon() 255 public Drawable loadBanner(PackageManager pm) { in loadBanner() 276 public Drawable loadDefaultIcon(PackageManager pm) { in loadDefaultIcon() 291 protected Drawable loadDefaultBanner(PackageManager pm) { in loadDefaultBanner() 306 public Drawable loadLogo(PackageManager pm) { in loadLogo() 327 protected Drawable loadDefaultLogo(PackageManager pm) { in loadDefaultLogo() 344 public XmlResourceParser loadXmlMetaData(PackageManager pm, String name) { in loadXmlMetaData() [all …]
|
/frameworks/base/core/java/android/service/voice/ |
D | VoiceInteractionServiceInfo.java | 22 import android.content.pm.PackageManager; 50 public VoiceInteractionServiceInfo(PackageManager pm, ComponentName comp) in VoiceInteractionServiceInfo() 51 throws PackageManager.NameNotFoundException { in VoiceInteractionServiceInfo() 52 this(pm, pm.getServiceInfo(comp, PackageManager.GET_META_DATA)); in VoiceInteractionServiceInfo() 55 public VoiceInteractionServiceInfo(PackageManager pm, ComponentName comp, int userHandle) in VoiceInteractionServiceInfo() 56 throws PackageManager.NameNotFoundException { in VoiceInteractionServiceInfo() 61 throws PackageManager.NameNotFoundException { in getServiceInfoOrThrow() 64 PackageManager.GET_META_DATA in getServiceInfoOrThrow() 65 | PackageManager.MATCH_DIRECT_BOOT_AWARE in getServiceInfoOrThrow() 66 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE in getServiceInfoOrThrow() [all …]
|
/frameworks/base/services/core/java/com/android/server/timezone/ |
D | PackageTrackerHelperImpl.java | 24 import android.content.pm.PackageManager; 41 private final PackageManager mPackageManager; 84 throws PackageManager.NameNotFoundException { in getInstalledPackageVersion() 85 int flags = PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS; in getInstalledPackageVersion() 91 public boolean isPrivilegedApp(String packageName) throws PackageManager.NameNotFoundException { in isPrivilegedApp() 92 int flags = PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS; in isPrivilegedApp() 99 throws PackageManager.NameNotFoundException { in usesPermission() 100 int flags = PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS in usesPermission() 101 | PackageManager.GET_PERMISSIONS; in usesPermission() 116 int flags = PackageManager.MATCH_DISABLED_UNTIL_USED_COMPONENTS; in contentProviderRegistered() [all …]
|
D | PackageManagerHelper.java | 20 import android.content.pm.PackageManager; 30 throws PackageManager.NameNotFoundException; in getInstalledPackageVersion() 32 boolean isPrivilegedApp(String packageName) throws PackageManager.NameNotFoundException; in isPrivilegedApp() 35 throws PackageManager.NameNotFoundException; in usesPermission() 40 throws PackageManager.NameNotFoundException; in receiverRegistered()
|
/frameworks/base/packages/EasterEgg/src/com/android/egg/neko/ |
D | NekoActivationActivity.java | 19 import android.content.pm.PackageManager; 36 final PackageManager pm = getPackageManager(); in onStart() 38 if (pm.getComponentEnabledSetting(cn) == PackageManager.COMPONENT_ENABLED_STATE_ENABLED) { in onStart() 42 pm.setComponentEnabledSetting(cn, PackageManager.COMPONENT_ENABLED_STATE_DISABLED, in onStart() 43 PackageManager.DONT_KILL_APP); in onStart() 50 pm.setComponentEnabledSetting(cn, PackageManager.COMPONENT_ENABLED_STATE_ENABLED, in onStart() 51 PackageManager.DONT_KILL_APP); in onStart()
|
/frameworks/support/compat/tests/java/android/support/v4/provider/ |
D | FontsContractCompatTest.java | 38 import android.content.pm.PackageManager; 39 import android.content.pm.PackageManager.NameNotFoundException; 76 PackageManager manager = context.getPackageManager(); 78 context.getPackageName(), PackageManager.GET_SIGNATURES); 85 } catch (PackageManager.NameNotFoundException e) { 281 PackageManager packageManager = mock(PackageManager.class); in testGetProvider_providerNotFound() 295 throws PackageManager.NameNotFoundException { in testGetProvider_noCerts() 296 PackageManager packageManager = mContext.getPackageManager(); in testGetProvider_noCerts() 306 throws PackageManager.NameNotFoundException { in testGetProvider_wrongCerts() 307 PackageManager packageManager = mock(PackageManager.class); in testGetProvider_wrongCerts() [all …]
|
/frameworks/support/wear/src/android/support/wear/utils/ |
D | MetadataConstants.java | 21 import android.content.pm.PackageManager; 139 context.getPackageName(), PackageManager.GET_META_DATA); in isStandalone() 143 } catch (PackageManager.NameNotFoundException e) { in isStandalone() 159 context.getPackageName(), PackageManager.GET_META_DATA); in isNotificationBridgingEnabled() 164 } catch (PackageManager.NameNotFoundException e) { in isNotificationBridgingEnabled() 182 context.getPackageName(), PackageManager.GET_META_DATA); in getPreviewDrawableResourceId() 188 } catch (PackageManager.NameNotFoundException e) { in getPreviewDrawableResourceId()
|
/frameworks/base/core/java/android/service/autofill/ |
D | AutofillServiceInfo.java | 23 import android.content.pm.PackageManager; 49 throws PackageManager.NameNotFoundException { in getServiceInfoOrThrow() 53 PackageManager.GET_META_DATA, in getServiceInfoOrThrow() 60 throw new PackageManager.NameNotFoundException(comp.toString()); in getServiceInfoOrThrow() 69 public AutofillServiceInfo(PackageManager pm, ComponentName comp, int userHandle) in AutofillServiceInfo() 70 throws PackageManager.NameNotFoundException { in AutofillServiceInfo() 74 public AutofillServiceInfo(PackageManager pm, ServiceInfo si) { in AutofillServiceInfo() 91 private static TypedArray getMetaDataArray(PackageManager pm, ServiceInfo si) { in getMetaDataArray() 132 } catch (PackageManager.NameNotFoundException e) { in getMetaDataArray()
|
/frameworks/base/packages/StatementService/src/com/android/statementservice/ |
D | IntentFilterVerificationReceiver.java | 22 import android.content.pm.PackageManager; 23 import android.content.pm.PackageManager.NameNotFoundException; 69 private static void sendErrorToPackageManager(PackageManager packageManager, in sendErrorToPackageManager() 72 PackageManager.INTENT_FILTER_VERIFICATION_FAILURE, in sendErrorToPackageManager() 86 PackageManager.EXTRA_INTENT_FILTER_VERIFICATION_ID); in onReceive() 88 PackageManager.EXTRA_INTENT_FILTER_VERIFICATION_URI_SCHEME); in onReceive() 90 PackageManager.EXTRA_INTENT_FILTER_VERIFICATION_HOSTS); in onReceive() 92 PackageManager.EXTRA_INTENT_FILTER_VERIFICATION_PACKAGE_NAME); in onReceive() 186 private final PackageManager mPackageManager; 188 public IsAssociatedResultReceiver(Handler handler, PackageManager packageManager, in IsAssociatedResultReceiver() [all …]
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/applications/ |
D | AppUtils.java | 23 import android.content.pm.PackageManager; 47 IUsbManager usbManager, PackageManager pm, Context context) { in getLaunchByDefaultSummary() 54 status != PackageManager.INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_UNDEFINED; in getLaunchByDefaultSummary() 71 public static boolean hasPreferredActivities(PackageManager pm, String packageName) { in hasPreferredActivities() 112 PackageManager packageManager, String packageName) { in getApplicationLabel() 117 PackageManager.MATCH_DISABLED_COMPONENTS in getApplicationLabel() 118 | PackageManager.MATCH_ANY_USER); in getApplicationLabel() 120 } catch (PackageManager.NameNotFoundException e) { in getApplicationLabel()
|
/frameworks/base/services/core/java/com/android/server/policy/ |
D | ShortcutManager.java | 23 import android.content.pm.PackageManager; 105 PackageManager packageManager = mContext.getPackageManager(); in loadShortcuts() 143 PackageManager.MATCH_DIRECT_BOOT_AWARE in loadShortcuts() 144 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE in loadShortcuts() 145 | PackageManager.MATCH_UNINSTALLED_PACKAGES); in loadShortcuts() 146 } catch (PackageManager.NameNotFoundException e) { in loadShortcuts() 152 PackageManager.MATCH_DIRECT_BOOT_AWARE in loadShortcuts() 153 | PackageManager.MATCH_DIRECT_BOOT_UNAWARE in loadShortcuts() 154 | PackageManager.MATCH_UNINSTALLED_PACKAGES); in loadShortcuts() 155 } catch (PackageManager.NameNotFoundException e1) { in loadShortcuts()
|
/frameworks/base/core/java/android/webkit/ |
D | WebViewFactory.java | 26 import android.content.pm.PackageManager; 155 PackageManager packageManager = AppGlobals.getInitialApplication().getPackageManager(); in loadWebViewNativeLibraryFromPackage() 159 PackageManager.GET_META_DATA | PackageManager.MATCH_DEBUG_TRIAGED_MISSING); in loadWebViewNativeLibraryFromPackage() 160 } catch (PackageManager.NameNotFoundException e) { in loadWebViewNativeLibraryFromPackage() 272 private static void fixupStubApplicationInfo(ApplicationInfo ai, PackageManager pm) in fixupStubApplicationInfo() 283 PackageManager.GET_SHARED_LIBRARY_FILES in fixupStubApplicationInfo() 284 | PackageManager.MATCH_DEBUG_TRIAGED_MISSING in fixupStubApplicationInfo() 285 | PackageManager.MATCH_UNINSTALLED_PACKAGES in fixupStubApplicationInfo() 286 | PackageManager.MATCH_FACTORY_ONLY); in fixupStubApplicationInfo() 287 } catch (PackageManager.NameNotFoundException e) { in fixupStubApplicationInfo() [all …]
|
/frameworks/base/telephony/java/com/android/internal/telephony/ |
D | CarrierAppUtils.java | 23 import android.content.pm.PackageManager; 149 PackageManager.COMPONENT_ENABLED_STATE_DEFAULT in disableCarrierAppsUntilPrivileged() 151 PackageManager.COMPONENT_ENABLED_STATE_DISABLED_UNTIL_USED)) { in disableCarrierAppsUntilPrivileged() 156 PackageManager.COMPONENT_ENABLED_STATE_ENABLED, in disableCarrierAppsUntilPrivileged() 157 PackageManager.DONT_KILL_APP, in disableCarrierAppsUntilPrivileged() 167 PackageManager.COMPONENT_ENABLED_STATE_DEFAULT in disableCarrierAppsUntilPrivileged() 169 PackageManager.COMPONENT_ENABLED_STATE_DISABLED_UNTIL_USED) { in disableCarrierAppsUntilPrivileged() 174 PackageManager.COMPONENT_ENABLED_STATE_ENABLED, in disableCarrierAppsUntilPrivileged() 175 PackageManager.DONT_KILL_APP, in disableCarrierAppsUntilPrivileged() 189 PackageManager.COMPONENT_ENABLED_STATE_DEFAULT) { in disableCarrierAppsUntilPrivileged() [all …]
|
/frameworks/base/services/core/java/com/android/server/webkit/ |
D | SystemImpl.java | 25 import android.content.pm.PackageManager; 26 import android.content.pm.PackageManager.NameNotFoundException; 160 PackageManager pm = AppGlobals.getInitialApplication().getPackageManager(); in getFactoryPackageVersion() 161 return pm.getPackageInfo(packageName, PackageManager.MATCH_FACTORY_ONLY).versionCode; in getFactoryPackageVersion() 227 PackageManager pm = AppGlobals.getInitialApplication().getPackageManager(); in uninstallAndDisablePackageForAllUsers() 234 }, PackageManager.DELETE_SYSTEM_APP | PackageManager.DELETE_ALL_USERS); in uninstallAndDisablePackageForAllUsers() 253 enable ? PackageManager.COMPONENT_ENABLED_STATE_DEFAULT : in enablePackageForUser() 254 PackageManager.COMPONENT_ENABLED_STATE_DISABLED_USER, 0, in enablePackageForUser() 270 PackageManager pm = AppGlobals.getInitialApplication().getPackageManager(); in getPackageInfoForProvider() 306 private final static int PACKAGE_FLAGS = PackageManager.GET_META_DATA [all …]
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/ |
D | DessertCase.java | 21 import android.content.pm.PackageManager; 31 PackageManager pm = getPackageManager(); in onStart() 33 if (pm.getComponentEnabledSetting(cn) != PackageManager.COMPONENT_ENABLED_STATE_ENABLED) { in onStart() 36 PackageManager.COMPONENT_ENABLED_STATE_ENABLED, in onStart() 37 PackageManager.DONT_KILL_APP); in onStart()
|
/frameworks/base/services/core/java/com/android/server/os/ |
D | SchedulingPolicyService.java | 19 import android.content.pm.PackageManager; 54 return PackageManager.PERMISSION_DENIED; in requestPriority() 63 return PackageManager.PERMISSION_DENIED; in requestPriority() 72 return PackageManager.PERMISSION_DENIED; in requestPriority() 74 return PackageManager.PERMISSION_GRANTED; in requestPriority()
|