Partager via


ClientHandler.SendAsync(HttpRequestMessage, CancellationToken) Méthode

Définition

Cela adapte HttpRequestMessages aux requêtes ASP.NET Core, les répartit via le pipeline et retourne le HttpResponseMessage associé.

protected:
 override System::Threading::Tasks::Task<System::Net::Http::HttpResponseMessage ^> ^ SendAsync(System::Net::Http::HttpRequestMessage ^ request, System::Threading::CancellationToken cancellationToken);
protected override System.Threading.Tasks.Task<System.Net.Http.HttpResponseMessage> SendAsync (System.Net.Http.HttpRequestMessage request, System.Threading.CancellationToken cancellationToken);
override this.SendAsync : System.Net.Http.HttpRequestMessage * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Net.Http.HttpResponseMessage>
Protected Overrides Function SendAsync (request As HttpRequestMessage, cancellationToken As CancellationToken) As Task(Of HttpResponseMessage)

Paramètres

request
HttpRequestMessage

L’HttpRequestMessageopérateur

cancellationToken
CancellationToken

L’CancellationTokenopérateur

Retours

Task<TResult> retourne le HttpResponseMessage.

S’applique à