共用方式為


WebAuthenticatorExtensions.AuthenticateAsync 方法

定義

流覽至指定的 URL 並等候回呼/重新導向至 callbackUrl 配置,以開始驗證流程。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<Microsoft::Maui::Authentication::WebAuthenticatorResult ^> ^ AuthenticateAsync(Microsoft::Maui::Authentication::IWebAuthenticator ^ webAuthenticator, Uri ^ url, Uri ^ callbackUrl);
public static System.Threading.Tasks.Task<Microsoft.Maui.Authentication.WebAuthenticatorResult> AuthenticateAsync (this Microsoft.Maui.Authentication.IWebAuthenticator webAuthenticator, Uri url, Uri callbackUrl);
static member AuthenticateAsync : Microsoft.Maui.Authentication.IWebAuthenticator * Uri * Uri -> System.Threading.Tasks.Task<Microsoft.Maui.Authentication.WebAuthenticatorResult>
<Extension()>
Public Function AuthenticateAsync (webAuthenticator As IWebAuthenticator, url As Uri, callbackUrl As Uri) As Task(Of WebAuthenticatorResult)

參數

webAuthenticator
IWebAuthenticator

IWebAuthenticator要用於驗證流程的 。

url
Uri

要巡覽至的 URL,開始驗證流程。

callbackUrl
Uri

流覽流程最終會重新導向至的預期回呼 URL。

傳回

傳回從回呼 URL 剖析的結果。

適用於