Targets represents possible log outputs. You can define one or more targets in the configuration file
with the
The following types of targets are supported by NLog:
Regular targets are responsible for writing log output to persistent media, such as files, databases, network receivers or message queues. Each target has its own set of type-specific configuration parameters which are passed as XML attributes or elements.
The following example defines a single file target with a file name of 'file.txt':
<targets>
<target name="n" type="File" fileName="file.txt"/>
</targets>
The following log targets are available. Click on a target name for a reference of possible target parameters.
Target wrappers are used to modify the behavior of other targets by adding features such as:
The following target wrappers are available. Click on a target name for full reference.
The following compound targets are available. Click on the target name for full reference.
| Name | Type | Description |
|---|
| Name | Type | Description |
|---|