Exposes the current LoggingTypeSource for a given role and Type.
Namespace: PostSharp.Patterns.Diagnostics
Assembly: PostSharp.Patterns.Diagnostics.dll
Syntax
public sealed class LoggingAbstractSource : ILogger3, ILogger2, ILogger, ILoggerExceptionHandlerProperties
| Name | Description |
|---|---|
| DefaultState | Gets the default LoggingSourceLocalState, i.e. the state when there is the context-local configuration has not been overridden by WithContextLocalConfiguration(LoggingContextLocalConfiguration). |
| Role | Gets the role. |
| Source | Gets the LoggingTypeSource currently assigned to Role and Type. |
| SourceName | Gets the name that this source is associated with. This can't be null. |
| Type | Gets the Type that this source is associated with. This may be null if the source is based on a logger name. |
Methods
| Name | Description |
|---|---|
| GetLocalState(out LoggingSourceLocalState) | Gets the LoggingSourceLocalState resolved for the current execution context. This method is used by generated code. |
| IsEnabled(LogLevel) | Determines whether logging is enabled for a given LogLevel for the current Role and Type. |