BaseAbstractAcquireTokenParameterBuilder<T>.ExecuteAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
ExecuteAsync() |
Executes the Token request asynchronously. |
ExecuteAsync(CancellationToken) |
Executes the Token request asynchronously, with a possibility of cancelling the asynchronous method. |
ExecuteAsync()
Executes the Token request asynchronously.
public System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> ExecuteAsync ();
member this.ExecuteAsync : unit -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public Function ExecuteAsync () As Task(Of AuthenticationResult)
Returns
Authentication result containing a token for the requested scopes and parameters set in the builder.
Applies to
ExecuteAsync(CancellationToken)
Executes the Token request asynchronously, with a possibility of cancelling the asynchronous method.
public abstract System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> ExecuteAsync (System.Threading.CancellationToken cancellationToken);
abstract member ExecuteAsync : System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public MustOverride Function ExecuteAsync (cancellationToken As CancellationToken) As Task(Of AuthenticationResult)
Parameters
- cancellationToken
- CancellationToken
Cancellation token. See CancellationToken
Returns
Authentication result containing a token for the requested scopes and parameters set in the builder.
Remarks
Cancellation is not guaranteed, it is best effort. If the operation reaches a point of no return, e.g. tokens are acquired and written to the cache, the task will complete even if cancellation was requested. Do not rely on cancellation tokens for strong consistency.
To learn more about potential exceptions thrown by the function, refer to Exceptions in MSAL.NET.
Applies to
Commentaires
https://aka.ms/ContentUserFeedback.
Bientôt disponible : Tout au long de 2024, nous allons supprimer progressivement GitHub Issues comme mécanisme de commentaires pour le contenu et le remplacer par un nouveau système de commentaires. Pour plus d’informations, consultezEnvoyer et afficher des commentaires pour