public LoggerTemplate(ILogger <T> logger, LoggerTemplateConfiguration loggerTemplateConfiguration)
 {
     _logger = logger;
     _loggerTemplateConfiguration = loggerTemplateConfiguration;
 }
Ejemplo n.º 2
0
 public static IServiceCollection AddLoggingTemplate(this IServiceCollection serviceCollection, LoggerTemplateConfiguration loggerTemplateConfiguration)
 {
     serviceCollection.TryAddSingleton(_ => loggerTemplateConfiguration);
     serviceCollection.TryAddSingleton(typeof(ILoggerTemplate <>), typeof(LoggerTemplate <>));
     return(serviceCollection);
 }