Method AddNLogToDatabase
- Namespace
 - Innova.NLogExtensions.RestServer
 
- Assembly
 - Innova.NLogExtensions.RestServer.dll
 
AddNLogToDatabase(WebApplicationBuilder, SqlConnectionOption)
Adds NLog to the database using the specified SQL connection option.
public static WebApplicationBuilder AddNLogToDatabase(this WebApplicationBuilder builder, SqlConnectionOption sqlConnectionOption)
Parameters
builderWebApplicationBuilderThe WebApplicationBuilder instance.
sqlConnectionOptionSqlConnectionOptionThe SQL connection option.
Returns
- WebApplicationBuilder
 The WebApplicationBuilder instance.
AddNLogToDatabase<TDBLogService>(WebApplicationBuilder, SqlConnectionOption)
Adds NLog to the database using the specified SQL connection option and a custom database logging service.
public static WebApplicationBuilder AddNLogToDatabase<TDBLogService>(this WebApplicationBuilder builder, SqlConnectionOption sqlConnectionOption) where TDBLogService : class, IDataBaseLoggingService
Parameters
builderWebApplicationBuilderThe WebApplicationBuilder instance.
sqlConnectionOptionSqlConnectionOptionThe SQL connection option.
Returns
- WebApplicationBuilder
 The WebApplicationBuilder instance.
Type Parameters
TDBLogServiceThe type of the custom database logging service.