/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/wifi/ |
D | WifiEnterpriseRestrictionUtilsTest.java | 67 when(mUserManager.hasUserRestriction(DISALLOW_WIFI_TETHERING)).thenReturn(true); in isWifiTetheringAllowed_hasDisallowRestriction_shouldReturnFalse() 74 when(mUserManager.hasUserRestriction(DISALLOW_WIFI_TETHERING)).thenReturn(false); in isWifiTetheringAllowed_noDisallowRestriction_shouldReturnTrue() 81 when(mUserManager.hasUserRestriction(DISALLOW_WIFI_DIRECT)).thenReturn(true); in isWifiDirectAllowed_hasDisallowRestriction_shouldReturnFalse() 88 when(mUserManager.hasUserRestriction(DISALLOW_WIFI_DIRECT)).thenReturn(false); in isWifiDirectAllowed_noDisallowRestriction_shouldReturnTrue() 95 when(mUserManager.hasUserRestriction(DISALLOW_ADD_WIFI_CONFIG)).thenReturn(true); in isAddWifiConfigAllowed_hasDisallowRestriction_shouldReturnFalse() 102 when(mUserManager.hasUserRestriction(DISALLOW_ADD_WIFI_CONFIG)).thenReturn(false); in isAddWifiConfigAllowed_noDisallowRestriction_shouldReturnTrue() 109 when(mUserManager.hasUserRestriction(DISALLOW_CHANGE_WIFI_STATE)).thenReturn(true); in isChangeWifiStateAllowed_hasDisallowRestriction_shouldReturnFalse() 116 when(mUserManager.hasUserRestriction(DISALLOW_CHANGE_WIFI_STATE)).thenReturn(false); in isChangeWifiStateAllowed_noDisallowRestriction_shouldReturnTrue() 132 when(mUserManager.hasUserRestriction(anyString())).thenReturn(false); in hasUserRestrictionFromT_setSDKForT_shouldReturnHasUserRestriction() 137 when(mUserManager.hasUserRestriction(anyString())).thenReturn(true); in hasUserRestrictionFromT_setSDKForT_shouldReturnHasUserRestriction()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | UserManagerServiceTest.java | 172 assertThat(mUserManagerService.hasUserRestriction(DISALLOW_USER_SWITCH, userId)).isTrue(); in assertHasUserRestriction() 175 assertThat(mUserManagerService.hasUserRestriction(DISALLOW_USER_SWITCH, userId)).isFalse(); in assertHasUserRestriction() 181 assertThat(mUserManagerService.hasUserRestriction(DISALLOW_USER_SWITCH, nonExistentUserId)) in testHasUserRestriction_NonExistentUserReturnsFalse() 198 assertThat(mUserManagerService.hasUserRestriction(DISALLOW_USER_SWITCH, incorrectId)) in testSetUserRestrictionWithIncorrectID() 201 assertThat(mUserManagerService.hasUserRestriction(DISALLOW_USER_SWITCH, incorrectId)) in testSetUserRestrictionWithIncorrectID()
|
D | UserManagerServiceUserInfoTest.java | 333 assertFalse(mUserManagerService.hasUserRestriction(restriction, userId)); in testUserRestrictionsUpgradeFromV9() 352 assertTrue(mUserManagerService.hasUserRestriction(restriction, userId)); in testUserRestrictionsUpgradeFromV9()
|
/frameworks/opt/telephony/src/java/com/android/internal/telephony/ |
D | TelephonyAdminReceiver.java | 42 mDisallowCellular2gRestriction = mUserManager.hasUserRestriction( in TelephonyAdminReceiver() 61 boolean shouldDisallow2g = mUserManager.hasUserRestriction( in onReceive()
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | TelephonyAdminReceiverTest.java | 74 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CELLULAR_2G)).thenReturn(false); in test_userRestrictionsNotChanged_noUpdate() 85 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CELLULAR_2G)).thenReturn( in test_userRestrictionToggled_shouldUpdate()
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/pm/ |
D | PackageHelperTestBase.kt | 104 whenever(rule.mocks().userManagerService.hasUserRestriction( in setup() 106 whenever(rule.mocks().userManagerService.hasUserRestriction( in setup()
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/development/ |
D | DevelopmentSettingsEnabler.java | 47 final boolean hasRestriction = um.hasUserRestriction( in isDevelopmentSettingsEnabled()
|
/frameworks/base/services/core/java/com/android/server/policy/ |
D | PowerAction.java | 45 if (!um.hasUserRestriction(UserManager.DISALLOW_SAFE_BOOT)) { in onLongPress()
|
D | RestartAction.java | 45 if (!um.hasUserRestriction(UserManager.DISALLOW_SAFE_BOOT)) { in onLongPress()
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/wifi/ |
D | WifiEnterpriseRestrictionUtils.java | 85 return userManager.hasUserRestriction(restrictionKey); in hasUserRestrictionFromT()
|
/frameworks/base/services/core/java/com/android/server/oemlock/ |
D | PersistentDataBlockLock.java | 67 .hasUserRestriction(UserManager.DISALLOW_OEM_UNLOCK, UserHandle.SYSTEM); in isOemUnlockAllowedByCarrier()
|
D | OemLockService.java | 258 .hasUserRestriction(UserManager.DISALLOW_FACTORY_RESET, UserHandle.SYSTEM); in isOemUnlockAllowedByAdmin()
|
/frameworks/base/services/core/java/com/android/server/pm/ |
D | RestrictionsSet.java | 193 boolean hasUserRestriction = mUserRestrictions.contains(userId); in remove() 195 return hasUserRestriction; in remove()
|
D | UserManagerInternal.java | 398 public abstract boolean hasUserRestriction(String restriction, int userId); in hasUserRestriction() method in UserManagerInternal
|
D | UserRestrictionsUtils.java | 792 if (mUserManager.hasUserRestriction( in isSettingRestrictedForUser() 908 return mUserManager.hasUserRestriction(restriction, UserHandle.of(userId)); in isSettingRestrictedForUser() 970 return (newValue || UserManager.get(context).hasUserRestriction(userRestriction, in getNewUserRestrictionSetting()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/connectivity/ |
D | AccessPointControllerImpl.java | 108 return !mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, in canConfigWifi() 113 return !mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_MOBILE_NETWORKS, in canConfigMobileData()
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/devicepolicy/ |
D | FactoryResetterTest.java | 259 when(mUm.hasUserRestriction(UserManager.DISALLOW_FACTORY_RESET)).thenReturn(false); in allowFactoryReset() 263 when(mUm.hasUserRestriction(UserManager.DISALLOW_FACTORY_RESET)).thenReturn(true); in disallowFactoryReset()
|
/frameworks/base/core/java/com/android/internal/app/ |
D | ConfirmUserCreationActivity.java | 105 boolean cantCreateUser = mUserManager.hasUserRestriction(UserManager.DISALLOW_ADD_USER) in checkUserCreationRequirements()
|
/frameworks/base/packages/VpnDialogs/src/com/android/vpndialogs/ |
D | ConfirmDialog.java | 113 if (UserManager.get(this).hasUserRestriction(UserManager.DISALLOW_CONFIG_VPN)) { in onCreate()
|
/frameworks/base/packages/SettingsProvider/test/src/com/android/providers/settings/ |
D | InstallNonMarketAppsDeprecationTest.java | 104 mHasUserRestriction = mUm.hasUserRestriction(UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES); in setUp()
|
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/ |
D | FactoryResetter.java | 127 if (!mForce && um.hasUserRestriction(UserManager.DISALLOW_FACTORY_RESET)) { in factoryResetInternalUnchecked()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/ |
D | BluetoothControllerImpl.java | 122 return !mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_BLUETOOTH, in canConfigBluetooth() 124 && !mUserManager.hasUserRestriction(UserManager.DISALLOW_BLUETOOTH, in canConfigBluetooth()
|
/frameworks/base/media/java/android/mtp/ |
D | MtpDevice.java | 89 if (!userManager.hasUserRestriction(UserManager.DISALLOW_USB_FILE_TRANSFER)) { in open()
|
/frameworks/base/core/java/android/os/ |
D | IUserManager.aidl | 95 boolean hasUserRestriction(in String restrictionKey, int userId); in hasUserRestriction() method
|
/frameworks/opt/net/wifi/libs/WifiTrackerLib/src/com/android/wifitrackerlib/ |
D | OsuWifiEntry.java | 83 mHasAddConfigUserRestriction = mUserManager.hasUserRestriction( in OsuWifiEntry()
|