CredentialManager.GetCredential メソッド

定義

オーバーロード

GetCredential(Context, GetCredentialRequest, CancellationSignal, IExecutor, IOutcomeReceiver)

ユーザーからアプリの資格情報を取得するために必要なフローを起動します。

GetCredential(Context, PrepareGetCredentialResponse+PendingGetCredentialHandle, CancellationSignal, IExecutor, IOutcomeReceiver)

GetCredential(Context, GetCredentialRequest, CancellationSignal, IExecutor, IOutcomeReceiver)

ユーザーからアプリの資格情報を取得するために必要なフローを起動します。

[Android.Runtime.Register("getCredential", "(Landroid/content/Context;Landroid/credentials/GetCredentialRequest;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Landroid/os/OutcomeReceiver;)V", "", ApiSince=34)]
public void GetCredential (Android.Content.Context context, Android.Credentials.GetCredentialRequest request, Android.OS.CancellationSignal? cancellationSignal, Java.Util.Concurrent.IExecutor executor, Android.OS.IOutcomeReceiver callback);
[<Android.Runtime.Register("getCredential", "(Landroid/content/Context;Landroid/credentials/GetCredentialRequest;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Landroid/os/OutcomeReceiver;)V", "", ApiSince=34)>]
member this.GetCredential : Android.Content.Context * Android.Credentials.GetCredentialRequest * Android.OS.CancellationSignal * Java.Util.Concurrent.IExecutor * Android.OS.IOutcomeReceiver -> unit

パラメーター

context
Context

必要な UI を起動するために使用されるコンテキスト。アクティビティ コンテキストを使用して、UI が同じタスク スタック内で起動されることを確認する

request
GetCredentialRequest

ユーザーから取得する資格情報の種類を指定する要求

cancellationSignal
CancellationSignal

この呼び出しを取り消すオプションのシグナル

executor
IExecutor

コールバックはこれに対して行われます Executor

callback
IOutcomeReceiver

要求が成功または失敗したときに呼び出されるコールバック

属性

注釈

ユーザーからアプリの資格情報を取得するために必要なフローを起動します。

この実行により、UI フローを起動して、資格情報の使用に対するユーザーの同意を収集したり、複数の資格情報が存在する場合にピッカーを表示したりできます。呼び出し元 (ブラウザーなど) は、必要に応じて独自のアプリとは異なるアプリの配信元 GetCredentialRequest を設定して、そのアプリの代わりに資格情報を取得できます。 この機能を使用するには、追加のアクセス許可 CREDENTIAL_MANAGER_SET_ORIGIN が必要です

の Java ドキュメント android.credentials.CredentialManager.getCredential(android.content.Context, android.credentials.GetCredentialRequest, android.os.CancellationSignal, java.util.concurrent.Executor, android.os.OutcomeReceiver<android.credentials.GetCredentialResponse, android.credentials.GetCredentialException>)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

GetCredential(Context, PrepareGetCredentialResponse+PendingGetCredentialHandle, CancellationSignal, IExecutor, IOutcomeReceiver)

[Android.Runtime.Register("getCredential", "(Landroid/content/Context;Landroid/credentials/PrepareGetCredentialResponse$PendingGetCredentialHandle;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Landroid/os/OutcomeReceiver;)V", "", ApiSince=34)]
public void GetCredential (Android.Content.Context context, Android.Credentials.PrepareGetCredentialResponse.PendingGetCredentialHandle pendingGetCredentialHandle, Android.OS.CancellationSignal? cancellationSignal, Java.Util.Concurrent.IExecutor executor, Android.OS.IOutcomeReceiver callback);
[<Android.Runtime.Register("getCredential", "(Landroid/content/Context;Landroid/credentials/PrepareGetCredentialResponse$PendingGetCredentialHandle;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Landroid/os/OutcomeReceiver;)V", "", ApiSince=34)>]
member this.GetCredential : Android.Content.Context * Android.Credentials.PrepareGetCredentialResponse.PendingGetCredentialHandle * Android.OS.CancellationSignal * Java.Util.Concurrent.IExecutor * Android.OS.IOutcomeReceiver -> unit

パラメーター

context
Context
cancellationSignal
CancellationSignal
executor
IExecutor
callback
IOutcomeReceiver
属性

適用対象