Click or drag to resize

NLog.Targets Namespace

Non-wrapper targets
Classes
  ClassDescription
Public classCode exampleAsyncTaskTarget
Abstract Target with async Task support
Public classAtomicFileTarget
Extended standard FileTarget with atomic file append for multi-process logging to the same file
Public classCode exampleColoredConsoleTarget
Writes log messages to the console with customizable coloring.
Public classConsoleRowHighlightingRule
The row-highlighting condition.
Public classCode exampleConsoleTarget
Writes log messages to the console.
Public classConsoleWordHighlightingRule
Highlighting rule for Win32 colorful console.
Public classConsoleWordHighlightingRuleRegex
Highlighting rule for Win32 colorful console.
Public classDatabaseCommandInfo
Information about database command + parameters.
Public classDatabaseObjectPropertyInfo
Information about object-property for the database-connection-object
Public classDatabaseParameterInfo
Represents a parameter to a Database target.
Public classCode exampleDatabaseTarget
Writes log messages to the database using an ADO.NET provider.
Public classCode exampleDebuggerTarget
Writes log messages to the attached managed debugger.
Public classDebugSystemTarget
Outputs log messages through WriteLine(String)
Public classCode exampleDebugTarget
Mock target - useful for testing.
Public classDefaultJsonSerializer
Default class for serialization of values to JSON format.
Public classDiagnosticListenerTarget
Redirects NLog LogEvents to named DiagnosticSource using DiagnosticListener
Public classCode exampleEventLogTarget
Writes log message to the Event Log.
Public classFileTarget
FileTarget for writing formatted messages to one or more log-files.
Public classGelfTarget
Sends log messages to GrayLog server using either TCP or UDP with GELF-format
Public classGZipFileTarget
Extended standard FileTarget with GZip compression as part of file-logging
Public classJsonSerializeOptions
Options for JSON serialization
Public classLineEndingMode
Line ending mode.
Public classLineEndingModeLineEndingModeConverter
Provides a type converter to convert LineEndingMode objects to and from other representations.
Public classCode exampleLog4JXmlTarget
Sends log messages to the remote instance of Chainsaw / NLogViewer application using Log4J Xml
Public classLogReceiverWebServiceTarget
Sends log messages to a NLog Receiver Service (using WCF or Web Services).
Public classCode exampleMemoryTarget
Writes log messages to Logs in memory for programmatic retrieval.
Public classCode exampleMessageQueueTarget
Writes log message to the specified message queue handled by MSMQ.
Public classMethodCallParameter
A parameter to MethodCall.
Public classCode exampleMethodCallTarget
Calls the specified static method on each log message and passes contextual parameters to it.
Public classMethodCallTargetBase
The base class for all targets which call methods (local or remote). Manages parameters and type coercion.
Public classNetworkLogEventDroppedEventArgs
Arguments for LogEventDropped events.
Public classCode exampleNetworkTarget
NetworkTarget for sending messages over the network using TCP / UDP sockets
Public classCode exampleNullTarget
Discards log messages. Used mainly for debugging and benchmarking.
Public classCode exampleOutputDebugStringTarget
Outputs log messages through the OutputDebugString() Win32 API.
Public classCode examplePerformanceCounterTarget
Increments specified performance counter on each write.
Public classSplunkTarget
Sends log messages to Splunk server using either TCP or UDP with Splunk-JSON-format
Public classSyslogTarget
Sends log messages to Syslog server using either TCP or UDP with format Rfc3164 or Rfc5424
Public classTarget
Represents logging target.
Public classTargetAttribute
Marks class as logging target and attaches a type-alias name for use in NLog configuration.
Public classTargetPropertyWithContext
Attribute details for TargetWithContext
Public classCode exampleTargetWithContext
Represents target that supports context capture of ScopeContext Properties + Nested-states
Public classTargetWithLayout
Represents target that supports string formatting using layouts.
Public classTargetWithLayoutHeaderAndFooter
Represents target that supports string formatting using layouts.
Public classCode exampleTraceTarget
Sends log messages through System.Diagnostics.Trace.
Public classCode exampleWebServiceTarget
Calls the specified web service on each log message.
Enumerations
  EnumerationDescription
Public enumerationConsoleOutputColor
Colored console output color.
Public enumerationEventLogTargetOverflowAction
Action that should be taken if the message is greater than the max message size allowed by the Event Log.
Public enumerationFileArchivePeriod
Modes of archiving files based on time.
Public enumerationNetworkLogEventDroppedReason
The reason why log event was dropped by NetworkTarget
Public enumerationNetworkTargetCompressionType
Type of compression for protocol payload
Public enumerationNetworkTargetConnectionsOverflowAction
The action to be taken when there are more connections then the max.
Public enumerationNetworkTargetOverflowAction
Action that should be taken if the message overflows.
Public enumerationNetworkTargetQueueOverflowAction
The action to be taken when the queue overflows.
Public enumerationWebServiceProtocol
Web service protocol.
Public enumerationWebServiceProxyType
Web Service Proxy Configuration Type