/frameworks/base/apct-tests/perftests/multiuser/src/android/multiuser/ |
D | UserLifecycleTests.java | 104 final UserInfo userInfo = mUm.createUser("TestUser", 0); in createAndStartUser() local 107 registerBroadcastReceiver(Intent.ACTION_USER_STARTED, latch, userInfo.id); in createAndStartUser() 108 mIam.startUserInBackground(userInfo.id); in createAndStartUser() 112 removeUser(userInfo.id); in createAndStartUser() 122 final UserInfo userInfo = mUm.createUser("TestUser", 0); in switchUser() local 125 switchUser(userInfo.id); in switchUser() 129 removeUser(userInfo.id); in switchUser() 179 final UserInfo userInfo = mUm.createUser("TestUser", 0); in stopUser() local 181 registerBroadcastReceiver(Intent.ACTION_USER_STARTED, latch, userInfo.id); in stopUser() 182 mIam.startUserInBackground(userInfo.id); in stopUser() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | UserManagerTest.java | 124 UserInfo userInfo = createUser("Guest 1", UserInfo.FLAG_GUEST); in testAddUser() local 125 assertTrue(userInfo != null); in testAddUser() 130 if (user.id == userInfo.id && user.name.equals("Guest 1") in testAddUser() 158 UserInfo userInfo = createUser("Guest 1", UserInfo.FLAG_GUEST); in testRemoveUser() local 159 removeUser(userInfo.id); in testRemoveUser() 161 assertFalse(findUser(userInfo.id)); in testRemoveUser() 166 UserInfo userInfo = createUser("Guest 1", UserInfo.FLAG_GUEST); in testRemoveUserByHandle() local 167 final UserHandle user = userInfo.getUserHandle(); in testRemoveUserByHandle() 184 assertFalse(findUser(userInfo.id)); in testRemoveUserByHandle() 209 UserInfo userInfo = createUser("SecondaryUser", /*flags=*/ 0); in testSetUserAdmin() local [all …]
|
D | UserLifecycleStressTest.java | 73 final UserInfo userInfo = mUserManager.createProfileForUser("TestUser", in stopManagedProfileStressTest() local 75 assertNotNull(userInfo); in stopManagedProfileStressTest() 79 ActivityManager.getService().startUserInBackground(userInfo.id)); in stopManagedProfileStressTest() 83 stopUser(userInfo.id); in stopManagedProfileStressTest() 85 mUserManager.removeUser(userInfo.id); in stopManagedProfileStressTest()
|
D | UserManagerServiceUserInfoTest.java | 111 UserInfo userInfo = mUserManagerService.getUserInfo(UserHandle.USER_SYSTEM); in testGetUserName() local 113 TextUtils.isEmpty(userInfo.name)); in testGetUserName() 115 userInfo = createUser(); in testGetUserName() 116 userInfo.partial = false; in testGetUserName() 118 userInfo.id = TEST_ID; in testGetUserName() 119 mUserManagerService.putUserInfo(userInfo); in testGetUserName()
|
/frameworks/base/services/core/java/com/android/server/pm/ |
D | UserManagerService.java | 752 UserInfo userInfo = mUsers.get(profileId).info; in getProfilesLU() local 755 userInfo = new UserInfo(userInfo); in getProfilesLU() 756 userInfo.name = null; in getProfilesLU() 757 userInfo.iconPath = null; in getProfilesLU() 759 userInfo = userWithName(userInfo); in getProfilesLU() 761 users.add(userInfo); in getProfilesLU() 821 UserInfo userInfo = getUserInfoLU(userId); in isSameProfileGroupNoChecks() local 822 if (userInfo == null || userInfo.profileGroupId == UserInfo.NO_PROFILE_GROUP_ID) { in isSameProfileGroupNoChecks() 830 return userInfo.profileGroupId == otherUserInfo.profileGroupId; in isSameProfileGroupNoChecks() 1159 UserInfo userInfo = getUserInfoLU(userId); in getManagedProfileBadge() local [all …]
|
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/ |
D | RestrictedLockUtilsTest.java | 184 UserInfo userInfo = setUpUser(mUserId, new ComponentName[] {mAdmin1}); in checkIfKeyguardFeaturesAreDisabled_doesMatchAllowedFeature_unifiedManagedProfile() local 186 when(mUserManager.getProfiles(mUserId)).thenReturn(Arrays.asList(userInfo, profileInfo)); in checkIfKeyguardFeaturesAreDisabled_doesMatchAllowedFeature_unifiedManagedProfile() 212 UserInfo userInfo = setUpUser(mUserId, new ComponentName[] {mAdmin1}); in checkIfKeyguardFeaturesAreDisabled_notMatchOtherFeatures_unifiedManagedProfile() local 214 when(mUserManager.getProfiles(mUserId)).thenReturn(Arrays.asList(userInfo, profileInfo)); in checkIfKeyguardFeaturesAreDisabled_notMatchOtherFeatures_unifiedManagedProfile() 235 UserInfo userInfo = setUpUser(mUserId, new ComponentName[] {mAdmin1}); in checkIfKeyguardFeaturesAreDisabled_onlyMatchesProfile_separateManagedProfile() local 237 when(mUserManager.getProfiles(mUserId)).thenReturn(Arrays.asList(userInfo, profileInfo)); in checkIfKeyguardFeaturesAreDisabled_onlyMatchesProfile_separateManagedProfile() 271 UserInfo userInfo = setUpUser(mUserId, new ComponentName[] {mAdmin1}); in checkIfKeyguardFeaturesAreDisabled_onlyMatchesParent_profileParentPolicy() local 273 when(mUserManager.getProfiles(mUserId)).thenReturn(Arrays.asList(userInfo, profileInfo)); in checkIfKeyguardFeaturesAreDisabled_onlyMatchesParent_profileParentPolicy() 311 UserInfo userInfo = new UserInfo(userId, "primary", 0); in setUpUser() local 312 when(mUserManager.getUserInfo(userId)).thenReturn(userInfo); in setUpUser() [all …]
|
/frameworks/base/packages/CarSystemUI/src/com/android/systemui/statusbar/car/ |
D | UserGridRecyclerView.java | 111 for (UserInfo userInfo : userInfoList) { in createUserRecords() 112 if (userInfo.isGuest()) { in createUserRecords() 118 mCarUserManagerHelper.getCurrentForegroundUserId() == userInfo.id; in createUserRecords() 119 UserRecord record = new UserRecord(userInfo, false /* isStartGuestSession */, in createUserRecords() 144 UserInfo userInfo = new UserInfo(); in createStartGuestUserRecord() local 145 userInfo.name = mContext.getString(R.string.start_guest_session); in createStartGuestUserRecord() 146 return new UserRecord(userInfo, true /* isStartGuestSession */, false /* isAddUser */, in createStartGuestUserRecord() 154 UserInfo userInfo = new UserInfo(); in createAddUserRecord() local 155 userInfo.name = mContext.getString(R.string.car_add_user); in createAddUserRecord() 156 return new UserRecord(userInfo, false /* isStartGuestSession */, in createAddUserRecord() [all …]
|
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/testutils/shadow/ |
D | ShadowUserManager.java | 54 final UserInfo userInfo = new UserInfo(); in addProfile() local 55 userInfo.id = id; in addProfile() 56 userInfo.name = name; in addProfile() 57 userInfoList.add(userInfo); in addProfile()
|
/frameworks/base/services/core/java/com/android/server/trust/ |
D | TrustManagerService.java | 380 for (UserInfo userInfo : userInfos) { in updateTrustAll() 381 updateTrust(userInfo.id, 0); in updateTrustAll() 495 for (UserInfo userInfo : userInfos) { in refreshAgentList() 496 if (userInfo == null || userInfo.partial || !userInfo.isEnabled() in refreshAgentList() 497 || userInfo.guestToRemove) continue; in refreshAgentList() 498 if (!userInfo.supportsSwitchToByUser()) { in refreshAgentList() 499 if (DEBUG) Slog.d(TAG, "refreshAgentList: skipping user " + userInfo.id in refreshAgentList() 503 if (!mActivityManager.isUserRunning(userInfo.id)) { in refreshAgentList() 504 if (DEBUG) Slog.d(TAG, "refreshAgentList: skipping user " + userInfo.id in refreshAgentList() 508 if (!lockPatternUtils.isSecure(userInfo.id)) { in refreshAgentList() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/ |
D | BaseLockSettingsServiceTests.java | 184 final UserInfo userInfo = new UserInfo( in installChildProfile() local 186 userInfo.profileGroupId = PRIMARY_USER_ID; in installChildProfile() 187 mPrimaryUserProfiles.add(userInfo); in installChildProfile() 188 when(mUserManager.getUserInfo(eq(profileId))).thenReturn(userInfo); in installChildProfile() 192 return userInfo; in installChildProfile() 196 final UserInfo userInfo = installChildProfile(profileId); in installAndTurnOffChildProfile() local 197 userInfo.flags |= UserInfo.FLAG_QUIET_MODE; in installAndTurnOffChildProfile() 200 return userInfo; in installAndTurnOffChildProfile()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/ |
D | UserInfoControllerImpl.java | 127 UserInfo userInfo; in queryForUserInformation() local 129 userInfo = ActivityManager.getService().getCurrentUser(); in queryForUserInformation() 131 new UserHandle(userInfo.id)); in queryForUserInformation() 139 final int userId = userInfo.id; in queryForUserInformation() 140 final boolean isGuest = userInfo.isGuest(); in queryForUserInformation() 141 final String userName = userInfo.name; in queryForUserInformation()
|
D | UserSwitcherController.java | 492 final UserInfo userInfo = mUserManager.getUserInfo(currentId); 504 if ((userInfo == null || !userInfo.isAdmin()) && record.isRestricted) { 520 if (userInfo != null && userInfo.id != UserHandle.USER_SYSTEM) { 522 UserHandle.of(userInfo.id)); 523 mSecondaryUser = userInfo.id;
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/ |
D | RestrictedLockUtilsInternal.java | 506 for (UserInfo userInfo : UserManager.get(context).getProfiles(userId)) { in checkForLockSetting() 507 final List<ComponentName> admins = dpm.getActiveAdminsAsUser(userInfo.id); in checkForLockSetting() 511 final UserHandle user = getUserHandleOf(userInfo.id); in checkForLockSetting() 513 sProxy.isSeparateProfileChallengeEnabled(lockPatternUtils, userInfo.id); in checkForLockSetting() 516 if (check.isEnforcing(dpm, admin, userInfo.id)) { in checkForLockSetting() 529 if (userInfo.isManagedProfile()) { in checkForLockSetting() 532 DevicePolicyManager parentDpm = sProxy.getParentProfileInstance(dpm, userInfo); in checkForLockSetting() 533 if (check.isEnforcing(parentDpm, admin, userInfo.id)) { in checkForLockSetting() 637 for (UserInfo userInfo : um.getProfiles(UserHandle.myUserId())) { in isAdminInCurrentUserOrProfile() 638 if (dpm.isAdminActiveAsUser(admin, userInfo.id)) { in isAdminInCurrentUserOrProfile()
|
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/ |
D | LockPatternUtilsTest.java | 73 final UserInfo userInfo = Mockito.mock(UserInfo.class); in configureTest() local 74 when(userInfo.isDemo()).thenReturn(isDemoUser); in configureTest() 76 when(um.getUserInfo(DEMO_USER_ID)).thenReturn(userInfo); in configureTest()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/theme/ |
D | ThemeOverlayController.java | 119 for (UserInfo userInfo : mUserManager.getEnabledProfiles(currentUser)) { in updateThemeOverlays() 120 if (userInfo.isManagedProfile()) { in updateThemeOverlays() 121 userHandles.add(userInfo.getUserHandle()); in updateThemeOverlays()
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | CarrierPrivilegesTrackerTest.java | 143 users.add(pkgCertInfo.userInfo); in setupInstalledPackages() 153 eq(pkgCertInfo.pkgName), eq(pkgCertInfo.userInfo.id))) in setupInstalledPackages() 546 public final UserInfo userInfo; field in CarrierPrivilegesTrackerTest.PackageCertInfo 549 PackageCertInfo(String pkgName, String cert, UserInfo userInfo, int uid) { in PackageCertInfo() argument 552 this.userInfo = userInfo; in PackageCertInfo()
|
/frameworks/base/services/core/java/com/android/server/am/ |
D | UserController.java | 536 UserInfo userInfo = getUserInfo(userId); in finishUserUnlockedCompleted() local 537 if (userInfo == null) { in finishUserUnlockedCompleted() 546 if (!userInfo.isInitialized()) { in finishUserUnlockedCompleted() 559 mInjector.getUserManager().makeInitialized(userInfo.id); in finishUserUnlockedCompleted() 567 if (userInfo.preCreated) { in finishUserUnlockedCompleted() 568 Slog.i(TAG, "Stopping pre-created user " + userInfo.toFullString()); in finishUserUnlockedCompleted() 573 stopUser(userInfo.id, /* force= */ true, /* stopUserCallback= */ null, in finishUserUnlockedCompleted() 832 UserInfo userInfo = getUserInfo(userId); 833 if (userInfo.isEphemeral() && !userInfo.preCreated) { 952 UserInfo userInfo = getUserInfo(oldUserId); [all …]
|
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/television/ |
D | UninstallAlertFragment.java | 73 UserInfo userInfo = userManager.getUserInfo(dialogInfo.user.getIdentifier()); in onCreateGuidance() local 75 getString(R.string.uninstall_application_text_user, userInfo.name)); in onCreateGuidance()
|
/frameworks/base/services/core/java/com/android/server/locksettings/ |
D | LockSettingsService.java | 824 final UserInfo userInfo = users.get(i); in migrateOldData() local 825 if (userInfo.isManagedProfile() && mStorage.hasChildProfileLock(userInfo.id)) { in migrateOldData() 833 DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, userInfo.id); in migrateOldData() 838 DevicePolicyManager.PASSWORD_QUALITY_ALPHANUMERIC, userInfo.id); in migrateOldData() 845 final String alias = LockPatternUtils.PROFILE_KEY_NAME_ENCRYPT + userInfo.id; in migrateOldData() 897 for (UserInfo userInfo : mUserManager.getUsers()) { in migrateFrpCredential() 898 if (userOwnsFrpCredential(mContext, userInfo) && isUserSecure(userInfo.id)) { in migrateFrpCredential() 900 if (isSyntheticPasswordBasedCredentialLocked(userInfo.id)) { in migrateFrpCredential() 902 DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, userInfo.id); in migrateFrpCredential() 905 getSyntheticPasswordHandleLocked(userInfo.id), in migrateFrpCredential() [all …]
|
/frameworks/base/media/java/android/media/session/ |
D | MediaSessionManager.java | 662 public boolean isTrustedForMediaControl(@NonNull RemoteUserInfo userInfo) { in isTrustedForMediaControl() argument 663 if (userInfo == null) { in isTrustedForMediaControl() 666 if (userInfo.getPackageName() == null) { in isTrustedForMediaControl() 671 userInfo.getPackageName(), userInfo.getPid(), userInfo.getUid()); in isTrustedForMediaControl()
|
/frameworks/base/core/java/android/provider/ |
D | CallLog.java | 870 final UserInfo userInfo = users.get(i); in addCall() local 871 final UserHandle userHandle = userInfo.getUserHandle(); in addCall() 920 final UserInfo userInfo = userManager.getUserInfo(userId); in shouldHaveSharedCallLogEntries() local 921 return userInfo != null && !userInfo.isManagedProfile(); in shouldHaveSharedCallLogEntries()
|
/frameworks/base/services/core/java/com/android/server/slice/ |
D | SliceFullAccessList.java | 105 for (UserInfo userInfo : activeUsers) { in readXml() 106 upgradeXml(xmlVersion, userInfo.getUserHandle().getIdentifier()); in readXml()
|
/frameworks/base/core/java/com/android/internal/app/ |
D | IntentForwarderActivity.java | 245 for (UserInfo userInfo : relatedUsers) { in getManagedProfile() 246 if (userInfo.isManagedProfile()) return userInfo.id; in getManagedProfile()
|
/frameworks/base/core/tests/coretests/src/android/content/ |
D | AbstractCrossUserContentResolverTest.java | 61 final UserInfo userInfo = createUser(); in setUp() local 62 mCrossUserId = userInfo.id; in setUp()
|
/frameworks/base/services/tests/uiservicestests/src/com/android/server/notification/ |
D | ManagedServicesTest.java | 405 for (UserInfo userInfo : mUm.getUsers()) { in testWriteXml_trimsMissingServices() 407 if (mExpectedPrimary.get(approvalLevel).containsKey(userInfo.id)) { in testWriteXml_trimsMissingServices() 409 mExpectedPrimary.get(approvalLevel).get(userInfo.id).split(":")) { in testWriteXml_trimsMissingServices() 416 if (mExpectedSecondary.get(approvalLevel).containsKey(userInfo.id)) { in testWriteXml_trimsMissingServices() 418 mExpectedSecondary.get(approvalLevel).get(userInfo.id).split(":")) { in testWriteXml_trimsMissingServices() 425 addExpectedServices(service, entriesExpectedToHaveServices, userInfo.id); in testWriteXml_trimsMissingServices() 432 for (UserInfo userInfo : mUm.getUsers()) { in testWriteXml_trimsMissingServices() 433 service.writeXml(serializer, true, userInfo.id); in testWriteXml_trimsMissingServices() 442 for (UserInfo userInfo : mUm.getUsers()) { in testWriteXml_trimsMissingServices() 443 service.readXml(parser, null, true, userInfo.id); in testWriteXml_trimsMissingServices()
|