Example #1
0
        public static ILoggerFactory AddColoredConsoleLogger(this ILoggerFactory loggerFactory, Action <ColoredConsoleLoggerConfiguration> configure)
        {
            var config = new ColoredConsoleLoggerConfiguration();

            configure(config);
            return(loggerFactory.AddColoredConsoleLogger(config));
        }
Example #2
0
 public static ILoggerFactory AddColoredConsoleLogger(this ILoggerFactory loggerFactory, ColoredConsoleLoggerConfiguration config)
 {
     loggerFactory.AddProvider(new ColoredConsoleLoggerProvider(config));
     return(loggerFactory);
 }
 public ColoredConsoleLoggerProvider(ColoredConsoleLoggerConfiguration config)
 {
     _config = config;
 }
Example #4
0
 public ColoredConsoleLogger(string name, ColoredConsoleLoggerConfiguration config)
 {
     _name   = name;
     _config = config;
 }