Home
last modified time | relevance | path

Searched refs:StorageManager (Results 1 – 25 of 84) sorted by relevance

1234

/frameworks/base/services/core/java/com/android/server/pm/
DUserDataPreparer.java23 import android.os.storage.StorageManager;
69 final StorageManager storage = mContext.getSystemService(StorageManager.class); in prepareUserData()
81 final StorageManager storage = mContext.getSystemService(StorageManager.class); in prepareUserDataLI()
85 if ((flags & StorageManager.FLAG_STORAGE_DE) != 0 && !mOnlyCore) { in prepareUserDataLI()
87 if (Objects.equals(volumeUuid, StorageManager.UUID_PRIVATE_INTERNAL)) { in prepareUserDataLI()
91 if ((flags & StorageManager.FLAG_STORAGE_CE) != 0 && !mOnlyCore) { in prepareUserDataLI()
93 if (Objects.equals(volumeUuid, StorageManager.UUID_PRIVATE_INTERNAL)) { in prepareUserDataLI()
103 StorageManager.FLAG_STORAGE_DE | StorageManager.FLAG_STORAGE_CE); in prepareUserDataLI()
117 final StorageManager storage = mContext.getSystemService(StorageManager.class); in destroyUserData()
126 final StorageManager storage = mContext.getSystemService(StorageManager.class); in destroyUserDataLI()
[all …]
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/
DUserDataPreparerTest.java22 import android.os.storage.StorageManager;
68 private StorageManager mStorageManagerMock;
86 when(mContextMock.getSystemServiceName(StorageManager.class)) in setup()
101 .prepareUserData(TEST_USER_ID, TEST_USER_SERIAL, StorageManager.FLAG_STORAGE_DE); in testPrepareUserData_De()
103 eq(TEST_USER_SERIAL), eq(StorageManager.FLAG_STORAGE_DE)); in testPrepareUserData_De()
105 eq(TEST_USER_SERIAL), eq(StorageManager.FLAG_STORAGE_DE)); in testPrepareUserData_De()
119 .prepareUserData(TEST_USER_ID, TEST_USER_SERIAL, StorageManager.FLAG_STORAGE_CE); in testPrepareUserData_Ce()
121 eq(TEST_USER_SERIAL), eq(StorageManager.FLAG_STORAGE_CE)); in testPrepareUserData_Ce()
123 eq(TEST_USER_SERIAL), eq(StorageManager.FLAG_STORAGE_CE)); in testPrepareUserData_Ce()
161 mUserDataPreparer.destroyUserData(TEST_USER_ID, StorageManager.FLAG_STORAGE_DE); in testDestroyUserData_De()
[all …]
/frameworks/base/cmds/sm/src/com/android/commands/sm/
DSm.java24 import android.os.storage.StorageManager;
137 System.out.println(SystemProperties.getBoolean(StorageManager.PROP_HAS_ADOPTABLE, false)); in runHasAdoptable()
146 mSm.setDebugFlags(forceAdoptable ? StorageManager.DEBUG_FORCE_ADOPTABLE : 0, in runSetForceAdoptable()
147 StorageManager.DEBUG_FORCE_ADOPTABLE); in runSetForceAdoptable()
151 final int mask = StorageManager.DEBUG_SDCARDFS_FORCE_ON in runSetSdcardfs()
152 | StorageManager.DEBUG_SDCARDFS_FORCE_OFF; in runSetSdcardfs()
155 mSm.setDebugFlags(StorageManager.DEBUG_SDCARDFS_FORCE_ON, mask); in runSetSdcardfs()
158 mSm.setDebugFlags(StorageManager.DEBUG_SDCARDFS_FORCE_OFF, mask); in runSetSdcardfs()
168 mSm.setDebugFlags(emulateFbe ? StorageManager.DEBUG_EMULATE_FBE : 0, in runSetEmulateFbe()
169 StorageManager.DEBUG_EMULATE_FBE); in runSetEmulateFbe()
[all …]
/frameworks/base/services/tests/servicestests/src/com/android/server/
DMountServiceTests.java24 import android.os.storage.StorageManager;
124 private StorageManager getStorageManager() { in getStorageManager()
125 return (StorageManager) getContext().getSystemService(Context.STORAGE_SERVICE); in getStorageManager()
128 private void mountObb(StorageManager sm, final int resource, final File file, in mountObb()
149 private ObbObserver mountObbWithoutWait(final StorageManager sm, final int resource, in mountObbWithoutWait()
160 private void waitForObbActionCompletion(final StorageManager sm, final File file, in waitForObbActionCompletion()
174 private String checkMountedPath(final StorageManager sm, final File file) { in checkMountedPath()
182 private void unmountObb(final StorageManager sm, final File file, int expectedState) { in unmountObb()
200 StorageManager sm = getStorageManager(); in testMountAndUnmountObbNormal()
219 StorageManager sm = getStorageManager(); in testAttemptMountNonObb()
[all …]
DMockLockSettingsContext.java24 import android.os.storage.StorageManager;
31 private StorageManager mStorageManager;
35 StorageManager storageManager) { in MockLockSettingsContext()
DBaseLockSettingsServiceTests.java33 import android.os.storage.StorageManager;
86 mDevicePolicyManager, mock(StorageManager.class)); in setUp()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/deviceinfo/
DStorageManagerVolumeProvider.java20 import android.os.storage.StorageManager;
31 private StorageManager mStorageManager;
33 public StorageManagerVolumeProvider(StorageManager sm) { in StorageManagerVolumeProvider()
/frameworks/base/core/java/com/android/internal/content/
DPackageHelper.java32 import android.os.storage.StorageManager;
352 abstract public StorageManager getStorageManager(Context context); in getStorageManager()
360 StorageManager storage = getStorageManager(context); in fitsOnInternalStorage()
371 public StorageManager getStorageManager(Context context) { in getDefaultTestableInterface()
372 return context.getSystemService(StorageManager.class); in getDefaultTestableInterface()
447 final StorageManager storageManager = in resolveInstallVolume()
453 return StorageManager.UUID_PRIVATE_INTERNAL; in resolveInstallVolume()
485 StorageManager.UUID_PRIVATE_INTERNAL)) { in resolveInstallVolume()
495 return StorageManager.UUID_PRIVATE_INTERNAL; in resolveInstallVolume()
503 if (Objects.equals(existingInfo.volumeUuid, StorageManager.UUID_PRIVATE_INTERNAL) in resolveInstallVolume()
[all …]
/frameworks/base/core/tests/coretests/src/android/app/
DApplicationPackageManagerTest.java23 import android.os.storage.StorageManager;
112 private StorageManager getMockedStorageManager() { in getMockedStorageManager()
113 StorageManager storageManager = Mockito.mock(StorageManager.class); in getMockedStorageManager()
149 StorageManager storageManager = getMockedStorageManager(); in testGetCandidateVolumes_systemApp()
178 StorageManager storageManager = getMockedStorageManager(); in testGetCandidateVolumes_3rdParty_internalOnly()
207 StorageManager storageManager = getMockedStorageManager(); in testGetCandidateVolumes_3rdParty_auto()
/frameworks/base/core/tests/coretests/src/android/content/pm/
DPackageHelperTests.java24 import android.os.storage.StorageManager;
53 private static final String sInternalVolUuid = StorageManager.UUID_PRIVATE_INTERNAL;
61 private static StorageManager sStorageManager;
63 private static StorageManager createStorageManagerMock() throws Exception { in createStorageManagerMock()
87 StorageManager storageManager = Mockito.mock(StorageManager.class); in createStorageManagerMock()
118 public StorageManager getStorageManager(Context context) { in getStorageManager()
240 assertEquals(StorageManager.UUID_PRIVATE_INTERNAL, volume); in testResolveInstallVolumeInternal_SystemApp()
246 assertEquals(StorageManager.UUID_PRIVATE_INTERNAL, volume); in testResolveInstallVolumeInternal_SystemApp()
252 assertEquals(StorageManager.UUID_PRIVATE_INTERNAL, volume); in testResolveInstallVolumeInternal_SystemApp()
258 assertEquals(StorageManager.UUID_PRIVATE_INTERNAL, volume); in testResolveInstallVolumeInternal_SystemApp()
/frameworks/base/services/core/java/com/android/server/storage/
DDeviceStorageMonitorService.java38 import android.os.storage.StorageManager;
188 final StorageManager storage = getContext().getSystemService(StorageManager.class); in check()
212 final UUID uuid = StorageManager.convert(vol.getFsUuid()); in check()
228 } else if (StorageManager.UUID_DEFAULT.equals(uuid) && !isBootImageOnDisk() in check()
313 return getContext().getSystemService(StorageManager.class)
430 if (StorageManager.UUID_DEFAULT.equals(uuid)) { in dumpImpl()
457 final UUID uuid = StorageManager.convert(vol.getFsUuid()); in updateNotifications()
460 Intent lowMemIntent = new Intent(StorageManager.ACTION_MANAGE_STORAGE); in updateNotifications()
461 lowMemIntent.putExtra(StorageManager.EXTRA_UUID, uuid); in updateNotifications()
468 if (StorageManager.UUID_DEFAULT.equals(uuid)) { in updateNotifications()
[all …]
DFileCollector.java25 import android.os.storage.StorageManager;
156 return collectFiles(StorageManager.maybeTranslateEmulatedPathToInternal(path), in getMeasurementResult()
173 StorageManager.UUID_PRIVATE_INTERNAL, in getMeasurementResult()
200 StorageManager sm = (StorageManager) context.getSystemService(Context.STORAGE_SERVICE); in getSystemSize()
/frameworks/base/packages/ExtServices/src/android/ext/services/storage/
DCacheQuotaServiceImpl.java22 import android.os.storage.StorageManager;
122 StorageManager storageManager = getSystemService(StorageManager.class); in getReservedCacheSize()
124 if (uuid == StorageManager.UUID_PRIVATE_INTERNAL) { // regular equals because of null in getReservedCacheSize()
/frameworks/base/services/core/java/com/android/server/
DStorageManagerService.java78 import android.os.storage.StorageManager;
406 final StorageManager storage = mContext.getSystemService(StorageManager.class); in findStorageForUuid()
407 if (Objects.equals(StorageManager.UUID_PRIVATE_INTERNAL, volumeUuid)) { in findStorageForUuid()
409 } else if (Objects.equals(StorageManager.UUID_PRIMARY_PHYSICAL, volumeUuid)) { in findStorageForUuid()
665 final int flags = shouldBenchmark() ? StorageManager.FSTRIM_FLAG_BENCHMARK : 0; in handleMessage()
881 && !StorageManager.isFileEncryptedNativeOnly()) { in initIfReadyAndConnected()
885 final boolean initLocked = StorageManager.isFileEncryptedEmulatedOnly(); in initIfReadyAndConnected()
1032 systemLocale = getField(StorageManager.SYSTEM_LOCALE_KEY); in copyLocaleFromMountService()
1079 if (SystemProperties.getBoolean(StorageManager.PROP_FORCE_ADOPTABLE, false) in onEventLocked()
1084 if (StorageManager.isFileEncryptedNativeOnly()) { in onEventLocked()
[all …]
DMasterClearReceiver.java25 import android.os.storage.StorageManager;
107 StorageManager sm = (StorageManager) mContext.getSystemService( in doInBackground()
DDiskStatsService.java24 import android.os.storage.StorageManager;
119 boolean fileBased = StorageManager.isFileEncryptedNativeOnly(); in dump()
120 boolean blockBased = fileBased ? false : StorageManager.isBlockEncrypted(); in dump()
/frameworks/base/packages/SharedStorageBackup/src/com/android/sharedstoragebackup/
DSharedStorageAgent.java9 import android.os.storage.StorageManager;
25 StorageManager mgr = (StorageManager) getSystemService(Context.STORAGE_SERVICE); in onCreate()
/frameworks/base/core/java/android/os/
DEnvironment.java21 import android.os.storage.StorageManager;
87 final StorageVolume[] volumes = StorageManager.getVolumeList(mUserId, in getExternalDirs()
88 StorageManager.FLAG_FOR_WRITE); in getExternalDirs()
822 final StorageVolume volume = StorageManager.getStorageVolume(path, UserHandle.myUserId()); in getExternalStorageState()
855 final StorageVolume volume = StorageManager.getStorageVolume(path, UserHandle.myUserId()); in isExternalStorageRemovable()
899 final StorageVolume volume = StorageManager.getStorageVolume(path, UserHandle.myUserId()); in isExternalStorageEmulated()
971 return StorageManager.maybeTranslateEmulatedPathToInternal(path); in maybeTranslateEmulatedPathToInternal()
DRevocableFileDescriptor.java20 import android.os.storage.StorageManager;
77 mOuter = context.getSystemService(StorageManager.class) in init()
/frameworks/base/packages/MtpDocumentsProvider/perf_tests/src/com/android/mtp/
DAppFusePerfTest.java24 import android.os.storage.StorageManager;
46 final StorageManager storageManager = context.getSystemService(StorageManager.class); in testReadWriteFile()
/frameworks/base/core/java/com/android/internal/widget/
DLockPatternUtils.java40 import android.os.storage.StorageManager;
588 updateEncryptionPassword(StorageManager.CRYPT_TYPE_DEFAULT, null); in clearLock()
655 updateEncryptionPassword(StorageManager.CRYPT_TYPE_PATTERN, stringPattern); in saveLockPattern()
682 storageManager.setField(StorageManager.OWNER_INFO_KEY, ownerInfo); in updateCryptoUserInfo()
798 int type = numeric || numericComplex ? StorageManager.CRYPT_TYPE_PIN in updateEncryptionPasswordIfNeeded()
799 : StorageManager.CRYPT_TYPE_PASSWORD; in updateEncryptionPasswordIfNeeded()
836 return StorageManager.isEncrypted(); in isDeviceEncryptionEnabled()
844 return StorageManager.isFileEncryptedNativeOrEmulated(); in isFileEncryptionEnabled()
851 updateEncryptionPassword(StorageManager.CRYPT_TYPE_DEFAULT, null); in clearEncryptionPassword()
1122 storageManager.setField(StorageManager.PATTERN_VISIBLE_KEY, enabled ? "1" : "0"); in setVisiblePatternEnabled()
[all …]
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DFrameworkFacade.java33 import android.os.storage.StorageManager;
163 return StorageManager.inCryptKeeperBounce(); in inStorageManagerCryptKeeperBounce()
/frameworks/base/packages/BackupRestoreConfirmation/src/com/android/backupconfirm/
DBackupRestoreConfirmation.java31 import android.os.storage.StorageManager;
275 != StorageManager.ENCRYPTION_STATE_NONE in deviceIsEncrypted()
277 != StorageManager.CRYPT_TYPE_DEFAULT; in deviceIsEncrypted()
/frameworks/base/packages/ExternalStorageProvider/src/com/android/externalstorage/
DExternalStorageProvider.java33 import android.os.storage.StorageManager;
97 private StorageManager mStorageManager;
108 mStorageManager = (StorageManager) getContext().getSystemService(Context.STORAGE_SERVICE); in onCreate()
150 storageUuid = StorageManager.UUID_DEFAULT; in updateVolumesLocked()
157 storageUuid = StorageManager.convert(privateVol.fsUuid); in updateVolumesLocked()
/frameworks/base/packages/ExtServices/tests/src/android/ext/services/storage/
DCacheQuotaServiceImplTest.java28 import android.os.storage.StorageManager;
50 @Mock(answer = Answers.RETURNS_DEEP_STUBS) private StorageManager mStorageManager;

1234