Class InnovaDatabaseTarget
- Namespace
- Innova.NLogExtensions
- Assembly
- Innova.NLogExtensions.dll
Represents a custom NLog target for logging to a database.
[Target("InnovaDatabase")]
public class InnovaDatabaseTarget : AsyncTaskTarget, IDisposable
- Inheritance
-
TargetTargetWithLayoutTargetWithContextAsyncTaskTargetInnovaDatabaseTarget
- Implements
Constructors
- InnovaDatabaseTarget()
Initializes a new instance of the InnovaDatabaseTarget class.
Properties
- ApplicationName
Gets or sets the application name.
- Parameters
Gets the list of database parameters.
Methods
- InitializeTarget()
Initializes the target.
- OnDatabaseError(Exception)
Handles the database error.
- WriteAsyncTask(LogEventInfo, CancellationToken)
Writes the log event to the database asynchronously.
- WriteAsyncTask(IList<LogEventInfo>, CancellationToken)
Writes the log events to the database asynchronously.