![]() | LogFactory Class |
Namespace: NLog
The LogFactory type exposes the following members.
Name | Description | |
---|---|---|
![]() | LogFactory |
Initializes a new instance of the LogFactory class.
|
![]() | LogFactory(LoggingConfiguration) |
Initializes a new instance of the LogFactory class.
|
Name | Description | |
---|---|---|
![]() | Configuration |
Gets or sets the current logging configuration. After setting this property all
existing loggers will be re-configured, so that there is no need to call ReconfigExistingLoggers
manually.
|
![]() ![]() | CurrentAppDomain |
Gets the current IAppDomain.
|
![]() | DefaultCultureInfo |
Gets the default culture info to use as FormatProvider.
|
![]() | GlobalThreshold |
Gets or sets the global log threshold. Log events below this threshold are not logged.
|
![]() | ThrowConfigExceptions |
Gets or sets a value indicating whether NLogConfigurationException should be thrown.
If null then ThrowExceptions is used.
|
![]() | ThrowExceptions |
Gets or sets a value indicating whether exceptions should be thrown. See also ThrowConfigExceptions.
|
Name | Description | |
---|---|---|
![]() | CreateNullLogger |
Creates a logger that discards all log messages.
|
![]() | DisableLogging | Obsolete.
Decreases the log enable counter and if it reaches -1 the logs are disabled.
|
![]() | Dispose |
Performs application-defined tasks associated with freeing, releasing, or resetting
unmanaged resources.
|
![]() | Dispose(Boolean) |
Releases unmanaged and - optionally - managed resources.
|
![]() | EnableLogging | Obsolete.
Increases the log enable counter and if it reaches 0 the logs are disabled.
|
![]() | Flush |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | Flush(Int32) |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | Flush(TimeSpan) |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | Flush(AsyncContinuation) |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | Flush(AsyncContinuation, Int32) |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | Flush(AsyncContinuation, TimeSpan) |
Flush any pending log messages (in case of asynchronous targets).
|
![]() | GetCurrentClassLogger |
Gets the logger with the name of the current class.
|
![]() | GetCurrentClassLogger(Type) |
Gets a custom logger with the name of the current class. Use loggerType to pass the type of the needed Logger.
|
![]() | GetCurrentClassLoggerT |
Gets the logger with the name of the current class.
|
![]() | GetLogger(String) |
Gets the specified named logger.
|
![]() | GetLogger(String, Type) |
Gets the specified named logger. Use loggerType to pass the type of the needed Logger.
|
![]() | GetLoggerT(String) |
Gets the specified named logger.
|
![]() | IsLoggingEnabled |
Returns if logging is currently enabled.
|
![]() | OnConfigurationChanged |
Invoke the Changed event; called whenever list changes
|
![]() | ReconfigExistingLoggers |
Loops through all loggers previously returned by GetLogger and recalculates their
target and filter list. Useful after modifying the configuration programmatically
to ensure that all loggers have been properly configured.
|
![]() | ResumeLogging |
Increases the log enable counter and if it reaches 0 the logs are disabled.
|
![]() | SuspendLogging |
Decreases the log enable counter and if it reaches -1 the logs are disabled.
|
Name | Description | |
---|---|---|
![]() | ConfigurationChanged |
Occurs when logging Configuration changes.
|
![]() | ConfigurationReloaded |
Occurs when logging Configuration gets reloaded.
|