ILayout Interface | Apache log4net™ SDK Documentation

Interface implemented by layout objects

Namespace: log4net.Layout
Assembly: log4net (in log4net.dll) Version: 2.0.8.0-.NET 4.0
Syntax

C#
VB
C++
F#
Copy

    public interface ILayout

    Public Interface ILayout

    public interface class ILayout

    type ILayout =  interface end

The ILayout type exposes the following members.

Properties

| Name | Description
--- | --- | ---
| ContentType | The content type output by this layout.
| Footer | The footer for the layout format.
| Header | The header for the layout format.
| IgnoresException | Flag indicating if this layout handle exceptions

Top
Methods

| Name | Description
--- | --- | ---
| Format | Implement this method to create your own layout format.

Top
Remarks

An ILayout object is used to format a LoggingEvent as text. The [M:Format(TextWriter,LoggingEvent)] method is called by an appender to transform the LoggingEvent into a string.

The layout can also supply Header and Footer text that is appender before any events and after all the events respectively.

See Also

#### Reference

log4net.Layout Namespace