Click or drag to resize

CompoundLayout Class

A layout containing one or more nested layouts.
Inheritance Hierarchy

Namespace:  NLog.Layouts
Assembly:  NLog (in NLog.dll) Version: 6.0.0+cfb73701cda54e2410b006f649f072e90daef707
Syntax
public class CompoundLayout : Layout

The CompoundLayout type exposes the following members.

Constructors
  NameDescription
Public methodCompoundLayout
Initializes a new instance of the CompoundLayout class.
Top
Properties
  NameDescription
Public propertyLayouts
Gets the inner layouts.
Protected propertyLoggingConfiguration
Gets the logging configuration this target is part of.
(Inherited from Layout.)
Top
Methods
  NameDescription
Protected methodCloseLayout
Closes the layout.
(Overrides LayoutCloseLayout.)
Protected methodGetFormattedMessage
Renders formatted output using the log event as context.
(Overrides LayoutGetFormattedMessage(LogEventInfo).)
Protected methodInitializeLayout
Initializes the layout.
(Overrides LayoutInitializeLayout.)
Public methodPrecalculate
Precalculates the layout for the specified log event and stores the result in per-log event cache. Skips context capture when Layout have [ThreadAgnostic], and only contains layouts with [ThreadAgnostic].
(Inherited from Layout.)
Public methodRender(LogEventInfo)
Renders formatted output using the log event as context.
(Inherited from Layout.)
Public methodRender(LogEventInfo, StringBuilder)
Optimized version of Render(LogEventInfo) that works best when override of RenderFormattedMessage(LogEventInfo, StringBuilder) is available.
(Inherited from Layout.)
Protected methodRenderFormattedMessage
Renders formatted output using the log event as context.
(Overrides LayoutRenderFormattedMessage(LogEventInfo, StringBuilder).)
Protected methodResolveServiceT
Resolve from DI ServiceRepository
(Inherited from Layout.)
Public methodToString
Returns a string that represents the current object.
(Overrides ObjectToString.)
Top
Remarks
See Also