Compartilhar via


PolicyHttpMessageHandler Construtores

Definição

Sobrecargas

PolicyHttpMessageHandler(IAsyncPolicy<HttpResponseMessage>)

Cria um novo PolicyHttpMessageHandler.

PolicyHttpMessageHandler(Func<HttpRequestMessage,IAsyncPolicy<HttpResponseMessage>>)

Cria um novo PolicyHttpMessageHandler.

PolicyHttpMessageHandler(IAsyncPolicy<HttpResponseMessage>)

Cria um novo PolicyHttpMessageHandler.

public:
 PolicyHttpMessageHandler(Polly::IAsyncPolicy<System::Net::Http::HttpResponseMessage ^> ^ policy);
public PolicyHttpMessageHandler (Polly.IAsyncPolicy<System.Net.Http.HttpResponseMessage> policy);
new Microsoft.Extensions.Http.PolicyHttpMessageHandler : Polly.IAsyncPolicy<System.Net.Http.HttpResponseMessage> -> Microsoft.Extensions.Http.PolicyHttpMessageHandler
Public Sub New (policy As IAsyncPolicy(Of HttpResponseMessage))

Parâmetros

policy
IAsyncPolicy<HttpResponseMessage>

A política.

Aplica-se a

PolicyHttpMessageHandler(Func<HttpRequestMessage,IAsyncPolicy<HttpResponseMessage>>)

Cria um novo PolicyHttpMessageHandler.

public:
 PolicyHttpMessageHandler(Func<System::Net::Http::HttpRequestMessage ^, Polly::IAsyncPolicy<System::Net::Http::HttpResponseMessage ^> ^> ^ policySelector);
public PolicyHttpMessageHandler (Func<System.Net.Http.HttpRequestMessage,Polly.IAsyncPolicy<System.Net.Http.HttpResponseMessage>> policySelector);
new Microsoft.Extensions.Http.PolicyHttpMessageHandler : Func<System.Net.Http.HttpRequestMessage, Polly.IAsyncPolicy<System.Net.Http.HttpResponseMessage>> -> Microsoft.Extensions.Http.PolicyHttpMessageHandler
Public Sub New (policySelector As Func(Of HttpRequestMessage, IAsyncPolicy(Of HttpResponseMessage)))

Parâmetros

policySelector
Func<HttpRequestMessage,IAsyncPolicy<HttpResponseMessage>>

Uma função que pode selecionar a política desejada para um determinado HttpRequestMessage.

Aplica-se a