Compartir a través de


SocketsHttpHandlerBuilderExtensions.Configure Método

Definición

Sobrecargas

Configure(ISocketsHttpHandlerBuilder, IConfiguration)

Usa IConfiguration para configurar la base de datos principal SocketsHttpHandler de un objeto denominado HttpClient.

Configure(ISocketsHttpHandlerBuilder, Action<SocketsHttpHandler,IServiceProvider>)

Agrega un delegado que se usará para configurar el objeto SocketsHttpHandler principal para un objeto HttpClient con nombre.

Configure(ISocketsHttpHandlerBuilder, IConfiguration)

Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs

Usa IConfiguration para configurar la base de datos principal SocketsHttpHandler de un objeto denominado HttpClient.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::ISocketsHttpHandlerBuilder ^ Configure(Microsoft::Extensions::DependencyInjection::ISocketsHttpHandlerBuilder ^ builder, Microsoft::Extensions::Configuration::IConfiguration ^ configuration);
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public static Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder Configure (this Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder builder, Microsoft.Extensions.Configuration.IConfiguration configuration);
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
static member Configure : Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder * Microsoft.Extensions.Configuration.IConfiguration -> Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder
<Extension()>
Public Function Configure (builder As ISocketsHttpHandlerBuilder, configuration As IConfiguration) As ISocketsHttpHandlerBuilder

Parámetros

builder
ISocketsHttpHandlerBuilder

El parámetro de cadena de consulta ISocketsHttpHandlerBuilder.

configuration
IConfiguration

Configuración que contiene propiedades de SocketsHttpHandler.

Devoluciones

que ISocketsHttpHandlerBuilder se puede usar para configurar el controlador.

Atributos

Comentarios

Solo se analizan las propiedades de SocketsHttpHandler tipo bool, int, Enumo TimeSpan .

Todas las propiedades no coincidentes de IConfiguration se omiten.

Se aplica a

Configure(ISocketsHttpHandlerBuilder, Action<SocketsHttpHandler,IServiceProvider>)

Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs
Source:
SocketsHttpHandlerBuilderExtensions.cs

Agrega un delegado que se usará para configurar el objeto SocketsHttpHandler principal para un objeto HttpClient con nombre.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::ISocketsHttpHandlerBuilder ^ Configure(Microsoft::Extensions::DependencyInjection::ISocketsHttpHandlerBuilder ^ builder, Action<System::Net::Http::SocketsHttpHandler ^, IServiceProvider ^> ^ configure);
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public static Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder Configure (this Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder builder, Action<System.Net.Http.SocketsHttpHandler,IServiceProvider> configure);
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
static member Configure : Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder * Action<System.Net.Http.SocketsHttpHandler, IServiceProvider> -> Microsoft.Extensions.DependencyInjection.ISocketsHttpHandlerBuilder
<Extension()>
Public Function Configure (builder As ISocketsHttpHandlerBuilder, configure As Action(Of SocketsHttpHandler, IServiceProvider)) As ISocketsHttpHandlerBuilder

Parámetros

builder
ISocketsHttpHandlerBuilder

El parámetro de cadena de consulta ISocketsHttpHandlerBuilder.

configure
Action<SocketsHttpHandler,IServiceProvider>

Delegado que se usa para modificar un SocketsHttpHandlerobjeto .

Devoluciones

que ISocketsHttpHandlerBuilder se puede usar para configurar el controlador.

Atributos

Se aplica a