Compartir a través de


PollyServiceCollectionExtensions.AddPolicyRegistry Método

Definición

Sobrecargas

AddPolicyRegistry(IServiceCollection)

Registra una instancia de PolicyRegistry vacía en la colección de servicios con los tipos de servicio IPolicyRegistry<TKey> y IReadOnlyPolicyRegistry<TKey>, y devuelve el registro recién creado.

AddPolicyRegistry(IServiceCollection, IPolicyRegistry<String>)

Registra la instancia de IPolicyRegistry<TKey> proporcionada en la colección de servicios con los tipos de servicio IPolicyRegistry<TKey> y IReadOnlyPolicyRegistry<TKey>, y devuelve el registro proporcionado.

AddPolicyRegistry(IServiceCollection, Action<IServiceProvider,IPolicyRegistry<String>>)

AddPolicyRegistry(IServiceCollection)

Registra una instancia de PolicyRegistry vacía en la colección de servicios con los tipos de servicio IPolicyRegistry<TKey> y IReadOnlyPolicyRegistry<TKey>, y devuelve el registro recién creado.

public:
[System::Runtime::CompilerServices::Extension]
 static Polly::Registry::IPolicyRegistry<System::String ^> ^ AddPolicyRegistry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services);
public static Polly.Registry.IPolicyRegistry<string> AddPolicyRegistry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);
static member AddPolicyRegistry : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Polly.Registry.IPolicyRegistry<string>
<Extension()>
Public Function AddPolicyRegistry (services As IServiceCollection) As IPolicyRegistry(Of String)

Parámetros

services
IServiceCollection

El parámetro de cadena de consulta IServiceCollection.

Devoluciones

Colección PolicyRegistry creada recientemente.

Se aplica a

AddPolicyRegistry(IServiceCollection, IPolicyRegistry<String>)

Registra la instancia de IPolicyRegistry<TKey> proporcionada en la colección de servicios con los tipos de servicio IPolicyRegistry<TKey> y IReadOnlyPolicyRegistry<TKey>, y devuelve el registro proporcionado.

public:
[System::Runtime::CompilerServices::Extension]
 static Polly::Registry::IPolicyRegistry<System::String ^> ^ AddPolicyRegistry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Polly::Registry::IPolicyRegistry<System::String ^> ^ registry);
public static Polly.Registry.IPolicyRegistry<string> AddPolicyRegistry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Polly.Registry.IPolicyRegistry<string> registry);
static member AddPolicyRegistry : Microsoft.Extensions.DependencyInjection.IServiceCollection * Polly.Registry.IPolicyRegistry<string> -> Polly.Registry.IPolicyRegistry<string>
<Extension()>
Public Function AddPolicyRegistry (services As IServiceCollection, registry As IPolicyRegistry(Of String)) As IPolicyRegistry(Of String)

Parámetros

Devoluciones

IPolicyRegistry<TKey> proporcionado.

Se aplica a

AddPolicyRegistry(IServiceCollection, Action<IServiceProvider,IPolicyRegistry<String>>)

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddPolicyRegistry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Action<IServiceProvider ^, Polly::Registry::IPolicyRegistry<System::String ^> ^> ^ configureRegistry);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddPolicyRegistry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<IServiceProvider,Polly.Registry.IPolicyRegistry<string>> configureRegistry);
static member AddPolicyRegistry : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<IServiceProvider, Polly.Registry.IPolicyRegistry<string>> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddPolicyRegistry (services As IServiceCollection, configureRegistry As Action(Of IServiceProvider, IPolicyRegistry(Of String))) As IServiceCollection

Parámetros

Devoluciones

Se aplica a