A global context for logger variables
Inheritance: IVariablesContext
コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MultiLogger"/> class.
 /// </summary>
 /// <param name="loggers">The loggers.</param>
 public MultiLogger(IEnumerable<ILog> loggers)
 {
     _loggers = loggers.ToList();
     GlobalVariablesContext = new MultiLoggerGlobalVariablesContext(_loggers);
     ThreadVariablesContext = new MultiLoggerThreadVariablesContext(_loggers);
     NestedThreadVariablesContext = new NoOpNestedVariablesContext();
 }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MultiLogger"/> class.
 /// </summary>
 /// <param name="loggers">The loggers.</param>
 public MultiLogger(IEnumerable <ILog> loggers)
 {
     _loggers = loggers.ToList();
     GlobalVariablesContext       = new MultiLoggerGlobalVariablesContext(_loggers);
     ThreadVariablesContext       = new MultiLoggerThreadVariablesContext(_loggers);
     NestedThreadVariablesContext = new NoOpNestedVariablesContext();
 }