Log4JXmlEventLayout Class |
Namespace: NLog.Layouts
The Log4JXmlEventLayout type exposes the following members.
Name | Description | |
---|---|---|
Log4JXmlEventLayout |
Initializes a new instance of the Log4JXmlEventLayout class.
|
Name | Description | |
---|---|---|
AppInfo |
Gets or sets the log4j:event log4japp-xml-element. By default it's the friendly name of the current AppDomain.
| |
FormattedMessage |
Gets or sets the log4j:event message-xml-element. Default: ${message}
| |
IncludeCallSite |
Gets or sets a value indicating whether to include call site (class and method name) in the information sent over the network.
| |
IncludeEventProperties |
Gets or sets the option to include all properties from the log events
| |
IncludeNdc |
Gets or sets whether to include log4j:NDC in output from ScopeContext nested context.
| |
IncludeScopeNested |
Gets or sets whether to include log4j:NDC in output from ScopeContext nested context.
| |
IncludeScopeProperties |
Gets or sets whether to include the contents of the ScopeContext properties-dictionary.
| |
IncludeSourceInfo |
Gets or sets a value indicating whether to include source info (file name and line number) in the information sent over the network.
| |
LoggerName |
Gets or sets the log4j:event logger-xml-attribute. Default: ${logger}
| |
LoggingConfiguration |
Gets the logging configuration this target is part of.
(Inherited from Layout.) | |
Parameters |
Gets the collection of parameters. Each parameter contains a mapping
between NLog layout and a named parameter.
| |
Renderer |
Gets the Log4JXmlEventLayoutRenderer instance that renders log events.
| |
WriteThrowableCData |
Gets or sets whether the log4j:throwable xml-element should be written as CDATA
|
Name | Description | |
---|---|---|
CloseLayout |
Closes the layout.
(Inherited from Layout.) | |
GetFormattedMessage |
Renders formatted output using the log event as context.
(Overrides LayoutGetFormattedMessage(LogEventInfo).) | |
InitializeLayout |
Initializes the layout.
(Inherited from Layout.) | |
Precalculate |
Precalculates the layout for the specified log event and stores the result
in per-log event cache.
Only if the layout doesn't have [ThreadAgnostic] and doesn't contain layouts with [ThreadAgnostic].
(Inherited from Layout.) | |
Render(LogEventInfo) |
Renders formatted output using the log event as context.
(Inherited from Layout.) | |
Render(LogEventInfo, StringBuilder) |
Optimized version of Render(LogEventInfo) that works best when
override of RenderFormattedMessage(LogEventInfo, StringBuilder) is available.
(Inherited from Layout.) | |
RenderFormattedMessage |
Renders formatted output using the log event as context.
(Overrides LayoutRenderFormattedMessage(LogEventInfo, StringBuilder).) | |
ResolveServiceT |
Resolve from DI ServiceRepository (Inherited from Layout.) |
This layout is not meant to be used explicitly. Instead you can use ${log4jxmlevent} layout renderer.
See NLog Wiki