SmsCodeAutofillClient.PermissionState

@Retention(value = RetentionPolicy.SOURCE)
@IntDef(value = [PermissionState.NONE, PermissionState.GRANTED, PermissionState.DENIED])
@Target(value = [ElementType.TYPE_PARAMETER, ElementType.TYPE_USE])
annotation SmsCodeAutofillClient.PermissionState


Permission states for the current user-designated autofill service. The initial state is NONE upon the first time using the SMS Code Autofill API. This permission can be granted or denied through a consent dialog requested by the current autofill service, or an explicit change by users within the SMS verification codes settings.

Summary

Constants

const Int
DENIED = 2

Indicates that the current autofill service has been denied permission by the user.

const Int

Indicates that the current autofill service has been granted permission by the user.

const Int
NONE = 0

Indicates that the current autofill service has not been granted or denied permission by the user.

Constants

DENIED

const val DENIED = 2: Int

Indicates that the current autofill service has been denied permission by the user. Calling startSmsCodeRetriever will fail with USER_PERMISSION_REQUIRED. It can only be resolved by the user explicitly turning on the permission in settings.

GRANTED

const val GRANTED = 1: Int

Indicates that the current autofill service has been granted permission by the user. The user consent is not required for calling startSmsCodeRetriever in this state.

NONE

const val NONE = 0: Int

Indicates that the current autofill service has not been granted or denied permission by the user. Calling startSmsCodeRetriever will fail with RESOLUTION_REQUIRED. The caller can use startResolutionForResult to show a consent dialog for requesting permission from the user.