diff options
author | 2023-11-29 17:20:03 +0000 | |
---|---|---|
committer | 2024-01-12 23:13:42 +0000 | |
commit | cf3d77ac7e4b553e5a949543a4d9020ac36bfa0c (patch) | |
tree | ece42124b55b7f7e2165b998b9295f0d1eab0642 | |
parent | 2452ea37f0d698cdbf240f7a888ee1a2f6f07fe2 (diff) |
Remove StorageManager#isUserKeyUnlocked()
StorageManager#isUserKeyUnlocked() is no longer used, since all callers
have switched to using StorageManager#isCeStorageUnlocked() which has a
clearer name. Therefore, remove StorageManager#isUserKeyUnlocked().
Note that isUserKeyUnlocked() is a @TestApi and isCeStorageUnlocked()
isn't. This is fine because no CTS tests call either method, so
@TestApi is unnecessary. And unlike regular APIs, Test APIs may be
added/changed/removed at any time. Of course, we can always add
@TestApi to isCeStorageUnlocked() later if it actually becomes needed.
Bug: 306204742
Test: build
Change-Id: Ibf7dcccf85bdc566941d6c401ca8ad3d19fd6fc1
-rw-r--r-- | core/api/test-current.txt | 1 | ||||
-rw-r--r-- | core/java/android/os/storage/StorageManager.java | 6 |
2 files changed, 0 insertions, 7 deletions
diff --git a/core/api/test-current.txt b/core/api/test-current.txt index d01706d85c59..d189a596aa29 100644 --- a/core/api/test-current.txt +++ b/core/api/test-current.txt @@ -2582,7 +2582,6 @@ package android.os.storage { method @NonNull public static String convert(@NonNull java.util.UUID); method @Nullable public String getCloudMediaProvider(); method public boolean isAppIoBlocked(@NonNull java.util.UUID, int, int, int); - method public static boolean isUserKeyUnlocked(int); field public static final String CACHE_RESERVE_PERCENT_HIGH_KEY = "cache_reserve_percent_high"; field public static final String CACHE_RESERVE_PERCENT_LOW_KEY = "cache_reserve_percent_low"; field public static final String STORAGE_THRESHOLD_PERCENT_HIGH_KEY = "storage_threshold_percent_high"; diff --git a/core/java/android/os/storage/StorageManager.java b/core/java/android/os/storage/StorageManager.java index eb1db3eaa06e..4c3f330ab4f3 100644 --- a/core/java/android/os/storage/StorageManager.java +++ b/core/java/android/os/storage/StorageManager.java @@ -1669,12 +1669,6 @@ public class StorageManager { } } - /** {@hide} */ - @TestApi - public static boolean isUserKeyUnlocked(int userId) { - return isCeStorageUnlocked(userId); - } - /** * Returns true if the user's credential-encrypted (CE) storage is unlocked. * |