-
@ExperimentalApi(value = https://github.com/grpc/grpc-java/issues/10566)@CheckReturnValue() public abstract class AsyncSecurityPolicy extends SecurityPolicy
Decides whether a given Android UID is authorized to access some resource.
This class provides the asynchronous version of SecurityPolicy, allowing implementations of authorization logic that involves slow or asynchronous calls without necessarily blocking the calling thread.
-
-
Method Summary
Modifier and Type Method Description final Status
checkAuthorization(int uid)
abstract ListenableFuture<Status>
checkAuthorizationAsync(int uid)
Decides whether the given Android UID is authorized. -
-
Method Detail
-
checkAuthorization
@Deprecated() final Status checkAuthorization(int uid)
-
checkAuthorizationAsync
abstract ListenableFuture<Status> checkAuthorizationAsync(int uid)
Decides whether the given Android UID is authorized. (Validity is implementation dependent).
As long as any given UID has active processes, this method should return the same value forthat UID. In order words, policy changes which occur while a transport instance is active, willhave no effect on that transport instance.
- Parameters:
uid
- The Android UID to authenticate.
-
-
-
-