Click or drag to resize

ConfigureExtensionsAddNLog Method (ILoggerFactory)

Note: This API is now obsolete.

Enable NLog as logging provider for Microsoft Extension Logging

Namespace:  NLog.Extensions.Logging
Assembly:  NLog.Extensions.Logging (in NLog.Extensions.Logging.dll) Version: 5.0.1+b127d73a8dd3e88e56cba56e4d025fce612bbc63
Syntax
[ObsoleteAttribute("Instead use ILoggingBuilder.AddNLog() or IHostBuilder.UseNLog()")]
public static ILoggerFactory AddNLog(
	this ILoggerFactory factory
)

Parameters

factory
Type: ILoggerFactory

Return Value

Type: ILoggerFactory
ILoggerFactory for chaining

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ILoggerFactory. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also