コード例 #1
0
        public CentralLogger(string categoryName, CentralLogOptions options)
        {
            this.categoryName = categoryName;
            this.options      = options;

            timer = new Timer(100);
            timer.Start();
            timer.AutoReset = false;
            timer.Elapsed  += ProcessJob;
        }
コード例 #2
0
 public CentralLogProvider(CentralLogOptions options)
 {
     this.options = options;
 }
コード例 #3
0
 public static ILoggingBuilder AddCentralLog(this ILoggingBuilder builder, CentralLogOptions options)
 {
     builder.Services.AddSingleton <CentralLogOptions>(options);
     builder.Services.AddSingleton <ILoggerProvider, CentralLogProvider>();
     return(builder);
 }