Click or drag to resize

LoggingRule Constructor (String, Target)

Create a (disabled) LoggingRule. You should call EnableLoggingForLevel(LogLevel) or EnableLoggingForLevels(LogLevel, LogLevel) to enable logging.

Namespace:  NLog.Config
Assembly:  NLog (in NLog.dll) Version: 6.0.0+cfb73701cda54e2410b006f649f072e90daef707
Syntax
public LoggingRule(
	string loggerNamePattern,
	Target target
)

Parameters

loggerNamePattern
Type: SystemString
Logger name pattern used for LoggerNamePattern. It may include one or more '*' or '?' wildcards at any position.
target
Type: NLog.TargetsTarget
Target to be written to when the rule matches.
See Also