ConsoleFormatter.Write<TState> Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Writes the log message to the specified TextWriter.
public:
generic <typename TState>
abstract void Write(Microsoft::Extensions::Logging::Abstractions::LogEntry<TState> ^ logEntry, Microsoft::Extensions::Logging::IExternalScopeProvider ^ scopeProvider, System::IO::TextWriter ^ textWriter);
public abstract void Write<TState>(in Microsoft.Extensions.Logging.Abstractions.LogEntry<TState> logEntry, Microsoft.Extensions.Logging.IExternalScopeProvider? scopeProvider, System.IO.TextWriter textWriter);
abstract member Write : LogEntry * Microsoft.Extensions.Logging.IExternalScopeProvider * System.IO.TextWriter -> unit
Public MustOverride Sub Write(Of TState) (logEntry As LogEntry(Of TState), scopeProvider As IExternalScopeProvider, textWriter As TextWriter)
Type Parameters
- TState
The type of the object to be written.
Parameters
- logEntry
- LogEntry<TState>
The log entry.
- scopeProvider
- IExternalScopeProvider
The provider of scope data.
- textWriter
- TextWriter
The string writer embedding ansi code for colors.
Remarks
If the formatter wants to write colors to the console, it can do so by embedding ANSI color codes into the string.
Applies to
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
.NET