Skip to main content

LogSuppressionMode Enumeration

Specifies how a logger compares log entries to determine their similarity for suppression purposes.

Definition​

Namespace: GHost.Core.Logging
Assembly: GHost.Core.dll

[Flags]
public enum LogSuppressionMode
{
None = 0x0,
Code = 0x1,
CodeAndParameters = 0x3,
CodeAndLevel = 0x5,
CodeParametersAndLevel = 0x7,
}

Fields​

NameValueDescription
None0Log suppression is disabled; every log entry is written regardless of code, parameters, or level.
Code1Suppression is based solely on the log code, regardless of parameters or level.
CodeAndParameters3Suppression is based on both the log code and parameters, but not level. Commonly used to suppress entries that represent the same event regardless of severity.
CodeAndLevel5Suppression is based on both the log code and level, but not parameters. Useful for suppressing entries that represent the same event at a specific severity.
CodeParametersAndLevel7Suppression is based on log code, parameters, and level. This is the most specific mode, matching entries that represent the same event, severity and parameter names and values.
note

The inclusion of Parameters in this mode property means that log parameters are compared by their names and values when determining if two log entries are similar enough to be suppressed.

See Also​