Merge "Accept UUID instead of String in notifyAppIo APIs" into sc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
3d28144bbd
@@ -241,8 +241,8 @@ package android.os {
|
|||||||
package android.os.storage {
|
package android.os.storage {
|
||||||
|
|
||||||
public class StorageManager {
|
public class StorageManager {
|
||||||
method public void notifyAppIoBlocked(@NonNull String, int, int, int);
|
method public void notifyAppIoBlocked(@NonNull java.util.UUID, int, int, int);
|
||||||
method public void notifyAppIoResumed(@NonNull String, int, int, int);
|
method public void notifyAppIoResumed(@NonNull java.util.UUID, int, int, int);
|
||||||
field public static final int APP_IO_BLOCKED_REASON_TRANSCODING = 0; // 0x0
|
field public static final int APP_IO_BLOCKED_REASON_TRANSCODING = 0; // 0x0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2766,10 +2766,11 @@ public class StorageManager {
|
|||||||
* @hide
|
* @hide
|
||||||
*/
|
*/
|
||||||
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
|
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
|
||||||
public void notifyAppIoBlocked(@NonNull String volumeUuid, int uid, int tid,
|
public void notifyAppIoBlocked(@NonNull UUID volumeUuid, int uid, int tid,
|
||||||
@AppIoBlockedReason int reason) {
|
@AppIoBlockedReason int reason) {
|
||||||
|
Objects.requireNonNull(volumeUuid);
|
||||||
try {
|
try {
|
||||||
mStorageManager.notifyAppIoBlocked(volumeUuid, uid, tid, reason);
|
mStorageManager.notifyAppIoBlocked(convert(volumeUuid), uid, tid, reason);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
throw e.rethrowFromSystemServer();
|
throw e.rethrowFromSystemServer();
|
||||||
}
|
}
|
||||||
@@ -2792,10 +2793,11 @@ public class StorageManager {
|
|||||||
* @hide
|
* @hide
|
||||||
*/
|
*/
|
||||||
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
|
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
|
||||||
public void notifyAppIoResumed(@NonNull String volumeUuid, int uid, int tid,
|
public void notifyAppIoResumed(@NonNull UUID volumeUuid, int uid, int tid,
|
||||||
@AppIoBlockedReason int reason) {
|
@AppIoBlockedReason int reason) {
|
||||||
|
Objects.requireNonNull(volumeUuid);
|
||||||
try {
|
try {
|
||||||
mStorageManager.notifyAppIoResumed(volumeUuid, uid, tid, reason);
|
mStorageManager.notifyAppIoResumed(convert(volumeUuid), uid, tid, reason);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
throw e.rethrowFromSystemServer();
|
throw e.rethrowFromSystemServer();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user