Merge "Update BiometricPrompt API naming"

This commit is contained in:
Kevin Chyn
2019-03-05 18:25:27 +00:00
committed by Android (Google) Code Review
7 changed files with 13 additions and 13 deletions

View File

@@ -125,7 +125,7 @@ public class KeyguardManager {
public static final int RESULT_ALTERNATE = 1;
/**
* @deprecated see {@link BiometricPrompt.Builder#setAllowDeviceCredential(boolean)}
* @deprecated see {@link BiometricPrompt.Builder#setDeviceCredentialAllowed(boolean)}
*
* Get an intent to prompt the user to confirm credentials (pin, pattern, password or biometrics
* if enrolled) for the current user of the device. The caller is expected to launch this

View File

@@ -128,7 +128,7 @@ public interface BiometricConstants {
/**
* The device does not have pin, pattern, or password set up. See
* {@link BiometricPrompt.Builder#setAllowDeviceCredential(boolean)} and
* {@link BiometricPrompt.Builder#setDeviceCredentialAllowed(boolean)} and
* {@link KeyguardManager#isDeviceSecure()}
*/
int BIOMETRIC_ERROR_NO_DEVICE_CREDENTIAL = 14;

View File

@@ -136,7 +136,7 @@ public interface BiometricFaceConstants {
/**
* The device does not have pin, pattern, or password set up. See
* {@link BiometricPrompt.Builder#setAllowDeviceCredential(boolean)} and
* {@link BiometricPrompt.Builder#setDeviceCredentialAllowed(boolean)} and
* {@link KeyguardManager#isDeviceSecure()}
*/
public static final int BIOMETRIC_ERROR_NO_DEVICE_CREDENTIAL = 14;

View File

@@ -121,7 +121,7 @@ public interface BiometricFingerprintConstants {
/**
* The device does not have pin, pattern, or password set up. See
* {@link BiometricPrompt.Builder#setAllowDeviceCredential(boolean)} and
* {@link BiometricPrompt.Builder#setDeviceCredentialAllowed(boolean)} and
* {@link KeyguardManager#isDeviceSecure()}
* @hide
*/

View File

@@ -204,7 +204,7 @@ public class BiometricPrompt implements BiometricAuthenticator, BiometricConstan
* "Cancel" button, but may be also used to show an alternative method for authentication,
* such as screen that asks for a backup password.
*
* Note that this should not be set if {@link #setAllowDeviceCredential(boolean)
* Note that this should not be set if {@link #setDeviceCredentialAllowed(boolean)}(boolean)
* is set to true.
*
* @param text
@@ -245,7 +245,7 @@ public class BiometricPrompt implements BiometricAuthenticator, BiometricConstan
*
* @param requireConfirmation
*/
@NonNull public Builder setRequireConfirmation(boolean requireConfirmation) {
@NonNull public Builder setConfirmationRequired(boolean requireConfirmation) {
mBundle.putBoolean(KEY_REQUIRE_CONFIRMATION, requireConfirmation);
return this;
}
@@ -261,12 +261,12 @@ public class BiometricPrompt implements BiometricAuthenticator, BiometricConstan
* Note that {@link #setNegativeButton(CharSequence, Executor,
* DialogInterface.OnClickListener)} should not be set if this is set to true.
*
* @param enable When true, the prompt will fall back to ask for the user's device
* @param allowed When true, the prompt will fall back to ask for the user's device
* credentials (PIN, pattern, or password).
* @return
*/
@NonNull public Builder setAllowDeviceCredential(boolean enable) {
mBundle.putBoolean(KEY_ALLOW_DEVICE_CREDENTIAL, enable);
@NonNull public Builder setDeviceCredentialAllowed(boolean allowed) {
mBundle.putBoolean(KEY_ALLOW_DEVICE_CREDENTIAL, allowed);
return this;
}

View File

@@ -8017,9 +8017,9 @@ public final class Settings {
/**
* Whether or not face unlock always requires user confirmation, meaning {@link
* android.hardware.biometrics.BiometricPrompt.Builder#setRequireConfirmation(boolean)}
* android.hardware.biometrics.BiometricPrompt.Builder#setConfirmationRequired(boolean)}
* is always 'true'. This overrides the behavior that apps choose in the
* setRequireConfirmation API.
* setConfirmationRequired API.
* @hide
*/
public static final String FACE_UNLOCK_ALWAYS_REQUIRE_CONFIRMATION =