Partager via


HttpClientBuilderExtensions.ConfigureAdditionalHttpMessageHandlers Méthode

Définition

Ajoute un délégué qui sera utilisé pour configurer des gestionnaires de messages supplémentaires à l’aide HttpMessageHandlerBuilder d’un nommé HttpClient.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IHttpClientBuilder ^ ConfigureAdditionalHttpMessageHandlers(Microsoft::Extensions::DependencyInjection::IHttpClientBuilder ^ builder, Action<System::Collections::Generic::IList<System::Net::Http::DelegatingHandler ^> ^, IServiceProvider ^> ^ configureAdditionalHandlers);
public static Microsoft.Extensions.DependencyInjection.IHttpClientBuilder ConfigureAdditionalHttpMessageHandlers (this Microsoft.Extensions.DependencyInjection.IHttpClientBuilder builder, Action<System.Collections.Generic.IList<System.Net.Http.DelegatingHandler>,IServiceProvider> configureAdditionalHandlers);
static member ConfigureAdditionalHttpMessageHandlers : Microsoft.Extensions.DependencyInjection.IHttpClientBuilder * Action<System.Collections.Generic.IList<System.Net.Http.DelegatingHandler>, IServiceProvider> -> Microsoft.Extensions.DependencyInjection.IHttpClientBuilder
<Extension()>
Public Function ConfigureAdditionalHttpMessageHandlers (builder As IHttpClientBuilder, configureAdditionalHandlers As Action(Of IList(Of DelegatingHandler), IServiceProvider)) As IHttpClientBuilder

Paramètres

configureAdditionalHandlers
Action<IList<DelegatingHandler>,IServiceProvider>

Délégué utilisé pour configurer une collection d’objets DelegatingHandler .

Retours

IHttpClientBuilder qui peut être utilisé pour configurer le client.

S’applique à