using Microsoft.Extensions.Logging.Log4Net.AspNetCore.Entities; using Microsoft.Extensions.Logging.Log4Net.AspNetCore.Scope; using System.Collections.Generic; namespace Microsoft.Extensions.Logging { /// /// The log4Net provider options. /// public sealed class Log4NetProviderOptions { /// /// The default log4 net file name /// private const string DefaultLog4NetFileName = "log4net.config"; /// /// Initializes a new instance of the class. /// public Log4NetProviderOptions() : this(DefaultLog4NetFileName) { } /// /// Initializes a new instance of the class. /// /// Name of the log4 net configuration file. public Log4NetProviderOptions(string log4NetConfigFileName) : this(log4NetConfigFileName, false) { } /// /// Initializes a new instance of the class. /// /// Name of the log4net configuration file. public Log4NetProviderOptions(string log4NetConfigFileName, bool watch) { this.Log4NetConfigFileName = log4NetConfigFileName; this.Watch = watch; this.OverrideCriticalLevelWith = string.Empty; this.Name = string.Empty; this.PropertyOverrides = new List(); this.ExternalConfigurationSetup = false; } /// /// Gets or sets the name. /// public string Name { get; set; } /// /// Gets or sets the name of the log file. /// public string Log4NetConfigFileName { get; set; } /// /// Gets or sets the logger repository. /// public string LoggerRepository { get; set; } /// /// Gets or sets the level value that should be used to override default's critical level. /// public string OverrideCriticalLevelWith { get; set; } /// /// Gets or sets the property overrides. /// public List PropertyOverrides { get; set; } /// /// Gets or sets a value indicating whether this is watch. /// public bool Watch { get; set; } /// /// Let user setup log4net externally /// public bool ExternalConfigurationSetup { get; set; } /// /// Let user setup log4net from web.config / app.config. /// public bool UseWebOrAppConfig { get; set; } /// /// Gets or sets the factory for the log4net ."/>. /// public ILog4NetLoggingEventFactory LoggingEventFactory { get; set; } /// /// Gets or sets the translator between the and the log4net . /// public ILog4NetLogLevelTranslator LogLevelTranslator { get; set; } } }