WrappingPrefixLogger class¶
Attributes: [DebuggerDisplay("WrappingPrefixLogger: {Level}")]
Defined in
Namespace: Splat Assembly: Splat.Logging.dll Full name: Splat.WrappingPrefixLogger Modifiers: public
Summary¶
View source (opens in a new tab)
Provides an ILogger implementation that prefixes all log messages with the name of a specified type, enabling easier
identification of log sources.
Applies to
net11.0, net10.0, net47, net471, net472, net48, net481
Class hierarchy
classDiagram
class WrappingPrefixLogger
class ILogger {
<<interface>>
}
ILogger <|.. WrappingPrefixLogger
Implements: ILogger
Remarks¶
This logger is useful for scenarios where log output should be clearly associated with a particular class or component. All log messages written through this logger are automatically prefixed with the name of the provided type, followed by a colon and a space. This can help distinguish log entries in applications with multiple components sharing a common logging infrastructure.
Constructors¶
| Name | Summary |
|---|---|
| .ctor | Provides an ILogger implementation that prefixes all log messages with the name of a specified type, enabling easier identification of log sources. |
Properties¶
| Name | Summary |
|---|---|
| Level | Gets the level at which the target will emit messages. |
Methods¶
| Name | Summary |
|---|---|
| Write | Writes a message to the target. |
Inherited members
System.Object.Equals(System.Object)(opens in a new tab)System.Object.Equals(System.Object,System.Object)(opens in a new tab)System.Object.GetHashCode(opens in a new tab)System.Object.GetType(opens in a new tab)System.Object.MemberwiseClone(opens in a new tab)System.Object.ReferenceEquals(System.Object,System.Object)(opens in a new tab)System.Object.ToString(opens in a new tab)