Android 12 Developer Preview is here! Try it out, and give us your feedback!

Builder

class Builder
kotlin.Any
   ↳ androidx.biometric.auth.CredentialAuthPrompt.Builder

Builder for a CredentialAuthPrompt with configurable options.

Summary

Public constructors
<init>(@NonNull title: CharSequence)

Constructs a prompt builder with the given required options.

Public methods
CredentialAuthPrompt

Creates a new prompt with the specified options.

CredentialAuthPrompt.Builder
setDescription(@NonNull description: CharSequence)

Sets a description that should be displayed on the prompt.

Public constructors

<init>

Builder(@NonNull title: CharSequence)

Constructs a prompt builder with the given required options.

Parameters
title CharSequence: The title to be displayed on the prompt.

Public methods

build

@NonNull fun build(): CredentialAuthPrompt

Creates a new prompt with the specified options.

Return
CredentialAuthPrompt An instance of CredentialAuthPrompt.

setDescription

@NonNull fun setDescription(@NonNull description: CharSequence): CredentialAuthPrompt.Builder

Sets a description that should be displayed on the prompt. Defaults to null.

Parameters
description CharSequence: A description for the prompt.
Return
CredentialAuthPrompt.Builder This builder.