Compartir a través de


EnrichmentServiceCollectionExtensions.AddStaticLogEnricher Método

Definición

Sobrecargas

AddStaticLogEnricher(IServiceCollection, IStaticLogEnricher)

Registra una instancia del enriquecidor de registro estático.

AddStaticLogEnricher<T>(IServiceCollection)

Registra un tipo de enriquecidor de registro estático.

AddStaticLogEnricher(IServiceCollection, IStaticLogEnricher)

Source:
EnrichmentServiceCollectionExtensions.cs

Registra una instancia del enriquecidor de registro estático.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddStaticLogEnricher(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Microsoft::Extensions::Diagnostics::Enrichment::IStaticLogEnricher ^ enricher);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddStaticLogEnricher (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Microsoft.Extensions.Diagnostics.Enrichment.IStaticLogEnricher enricher);
static member AddStaticLogEnricher : Microsoft.Extensions.DependencyInjection.IServiceCollection * Microsoft.Extensions.Diagnostics.Enrichment.IStaticLogEnricher -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddStaticLogEnricher (services As IServiceCollection, enricher As IStaticLogEnricher) As IServiceCollection

Parámetros

services
IServiceCollection

Contenedor de inserción de dependencias al que se va a agregar la instancia del enriquecidor.

enricher
IStaticLogEnricher

Instancia del enriquecidor que se va a agregar.

Devoluciones

El valor de services.

Excepciones

services o enricher es null.

Se aplica a

AddStaticLogEnricher<T>(IServiceCollection)

Source:
EnrichmentServiceCollectionExtensions.cs

Registra un tipo de enriquecidor de registro estático.

public:
generic <typename T>
 where T : class, Microsoft::Extensions::Diagnostics::Enrichment::IStaticLogEnricher[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddStaticLogEnricher(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddStaticLogEnricher<T> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services) where T : class, Microsoft.Extensions.Diagnostics.Enrichment.IStaticLogEnricher;
static member AddStaticLogEnricher : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'T : null and 'T :> Microsoft.Extensions.Diagnostics.Enrichment.IStaticLogEnricher)
<Extension()>
Public Function AddStaticLogEnricher(Of T As {Class, IStaticLogEnricher}) (services As IServiceCollection) As IServiceCollection

Parámetros de tipo

T

Tipo de enriquecimiento.

Parámetros

services
IServiceCollection

Contenedor de inserción de dependencias al que se va a agregar el tipo de enriquecido.

Devoluciones

El valor de services.

Excepciones

services es null.

Se aplica a