This class routes log messages to LogTargets based on categories.
Initializes a new LogWriter with the specified LogTargets, a Warning minimum level and Basic default category.
public Void LogWriter(logTargets)
Name | Type | Summary |
---|---|---|
logTargets | ICollection<LogTarget> | A collection of LogTargets. |
Initializes a new LogWriter with the specified LogTargets, a Warning minimum level and the specified defaultCategory.
public Void LogWriter(defaultCategory, logTargets)
Name | Type | Summary |
---|---|---|
defaultCategory | String | Default category for log entries. |
logTargets | ICollection<LogTarget> | A collection of LogTargets. |
Initializes a new LogWriter with the specified LogTargets, ant the specified minimumLevel and defaultCategory.
public Void LogWriter(minimumLevel, defaultCategory, logTargets)
Name | Type | Summary |
---|---|---|
minimumLevel | LogLevel | Minimum entry level to be writter. |
defaultCategory | String | Default category for log entries. |
logTargets | ICollection<LogTarget> | A collection of LogTargets. |
Default LogEntry category.
public String DefaultCategory { get; set; }
A collection of LogTargets to write the entries to.
public ICollection<LogTarget> LogTargets { get; set; }
Minimum entry level to be written.
public LogLevel MinimumLevel { get; set; }
Queries whether the entry should be logged.
public Boolean ShouldLog(entry)
true if the entry should be written, otherwise false.
Name | Type | Summary |
---|---|---|
entry | LogEntry | An LogEntry to be checked. |
Returns a textual representation of the Log Writer.
public String ToString()
In this document