ConsoleLoggerExtensions.AddConsoleFormatter Methode

Definition

Überlädt

AddConsoleFormatter<TFormatter,TOptions>(ILoggingBuilder)

Fügt der Konsolenprotokollierung einen benutzerdefinierten Formatierer hinzu.

AddConsoleFormatter<TFormatter,TOptions>(ILoggingBuilder, Action<TOptions>)

Fügt einen benutzerdefinierten Formatierer für die Konsolenprotokollierung hinzu, der mit den angegebenen Optionen konfiguriert werden soll.

AddConsoleFormatter<TFormatter,TOptions>(ILoggingBuilder)

Fügt der Konsolenprotokollierung einen benutzerdefinierten Formatierer hinzu.

public:
generic <typename TFormatter, typename TOptions>
 where TFormatter : Microsoft::Extensions::Logging::Console::ConsoleFormatter where TOptions : Microsoft::Extensions::Logging::Console::ConsoleFormatterOptions[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Logging::ILoggingBuilder ^ AddConsoleFormatter(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder);
public static Microsoft.Extensions.Logging.ILoggingBuilder AddConsoleFormatter<TFormatter,TOptions> (this Microsoft.Extensions.Logging.ILoggingBuilder builder) where TFormatter : Microsoft.Extensions.Logging.Console.ConsoleFormatter where TOptions : Microsoft.Extensions.Logging.Console.ConsoleFormatterOptions;
static member AddConsoleFormatter : Microsoft.Extensions.Logging.ILoggingBuilder -> Microsoft.Extensions.Logging.ILoggingBuilder (requires 'Formatter :> Microsoft.Extensions.Logging.Console.ConsoleFormatter and 'Options :> Microsoft.Extensions.Logging.Console.ConsoleFormatterOptions)
<Extension()>
Public Function AddConsoleFormatter(Of TFormatter As ConsoleFormatter, TOptions As ConsoleFormatter) (builder As ILoggingBuilder) As ILoggingBuilder

Typparameter

TFormatter

Der benutzerdefinierte Konsolenprotokollierer.

TOptions

Die Konfigurationsoptionen.

Parameter

builder
ILoggingBuilder

Die aktuell zu verwendende Protokollierungs-Generator-Instanz.

Gibt zurück

ILoggingBuilder

Die aktuelle Protokollierungs-Generator-Instanz, damit weitere Aufrufe verkettet werden können.

Gilt für

AddConsoleFormatter<TFormatter,TOptions>(ILoggingBuilder, Action<TOptions>)

Fügt einen benutzerdefinierten Formatierer für die Konsolenprotokollierung hinzu, der mit den angegebenen Optionen konfiguriert werden soll.

public:
generic <typename TFormatter, typename TOptions>
 where TFormatter : Microsoft::Extensions::Logging::Console::ConsoleFormatter where TOptions : Microsoft::Extensions::Logging::Console::ConsoleFormatterOptions[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Logging::ILoggingBuilder ^ AddConsoleFormatter(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder, Action<TOptions> ^ configure);
public static Microsoft.Extensions.Logging.ILoggingBuilder AddConsoleFormatter<TFormatter,TOptions> (this Microsoft.Extensions.Logging.ILoggingBuilder builder, Action<TOptions> configure) where TFormatter : Microsoft.Extensions.Logging.Console.ConsoleFormatter where TOptions : Microsoft.Extensions.Logging.Console.ConsoleFormatterOptions;
static member AddConsoleFormatter : Microsoft.Extensions.Logging.ILoggingBuilder * Action<'Options (requires 'Options :> Microsoft.Extensions.Logging.Console.ConsoleFormatterOptions)> -> Microsoft.Extensions.Logging.ILoggingBuilder (requires 'Formatter :> Microsoft.Extensions.Logging.Console.ConsoleFormatter and 'Options :> Microsoft.Extensions.Logging.Console.ConsoleFormatterOptions)
<Extension()>
Public Function AddConsoleFormatter(Of TFormatter As ConsoleFormatter, TOptions As ConsoleFormatter) (builder As ILoggingBuilder, configure As Action(Of TOptions)) As ILoggingBuilder

Typparameter

TFormatter

Der benutzerdefinierte Konsolenprotokollierer.

TOptions

Die Konfigurationsoptionen.

Parameter

builder
ILoggingBuilder

Die aktuell zu verwendende Protokollierungs-Generator-Instanz.

configure
Action<TOptions>

Ein Delegat zum Konfigurieren von TOptions für den benutzerdefinierten Formatierer TFormatter.

Gibt zurück

ILoggingBuilder

Die aktuelle Protokollierungs-Generator-Instanz, damit weitere Aufrufe verkettet werden können.

Gilt für