Skip to content

bd483552 379c 697b ab08 ed1abbf590bb

Axel Kesseler edited this page Mar 1, 2023 · 6 revisions

CompositeLoggerExtension.AddConsoleLogger(TContext) Method (ICompositeLogger(TContext), IConsoleLoggerSettings, Boolean)

Adds a new console logger with setting of provided settings parameter.

Namespace: Plexdata.LogWriter.Extensions
Assembly: Plexdata.LogWriter.Composite (in Plexdata.LogWriter.Composite.dll) Version: 1.0.7.1

Syntax

C#

public static ICompositeLogger<TContext> AddConsoleLogger<TContext>(
	this ICompositeLogger<TContext> parent,
	IConsoleLoggerSettings settings,
	bool windows
)

Parameters

 

parent
Type: Plexdata.LogWriter.Abstraction.ICompositeLogger(TContext)
The composite logger to add the console logger to.
settings
Type: Plexdata.LogWriter.Abstraction.IConsoleLoggerSettings
The settings to get all console logger settings from.
windows
Type: System.Boolean
True to choose the windows version and false to take the standard version instead.

Type Parameters

 

TContext
The type of the logger context.

Return Value

Type: ICompositeLogger(TContext)
The provided composite logger.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ICompositeLogger(TContext). 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).

Remarks

This method adds a new console logger using the settings parameter to read settings from.

See Also

Reference

CompositeLoggerExtension Class
AddConsoleLogger Overload
Plexdata.LogWriter.Extensions Namespace

Clone this wiki locally