C# Class AWSAppender.Core.Appenders.RenderingForwardingAppender

This appender forwards logging events to attached appenders.

The forwarding appender can be used to specify different thresholds and filters for the same appender at different locations within the hierarchy.

Inheritance: log4net.Appender.AppenderSkeleton, IAppenderAttachable
Show file Open project: camitz/CloudWatchAppender

Public Methods

Method Description
AddAppender ( IAppender newAppender ) : void

Adds an IAppender to the list of appenders of this instance.

If the specified IAppender is already in the list of appenders, then it won't be added again.

GetAppender ( string name ) : IAppender

Looks for the appender with the specified name.

Get the named appender attached to this appender.

RemoveAllAppenders ( ) : void

Removes all previously added appenders from this appender.

This is useful when re-reading configuration information.

RemoveAppender ( IAppender appender ) : IAppender

Removes the specified appender from the list of appenders.

The appender removed is not closed. If you are discarding the appender you must call IAppender.Close on the appender removed.

RemoveAppender ( string name ) : IAppender

Removes the appender with the specified name from the list of appenders.

The appender removed is not closed. If you are discarding the appender you must call IAppender.Close on the appender removed.

RenderingForwardingAppender ( ) : System

Initializes a new instance of the ForwardingAppender class.

Default constructor.

Protected Methods

Method Description
Append ( log4net.Core.LoggingEvent loggingEvent ) : void

Forward the logging event to the attached appenders

Delivers the logging event to all the attached appenders.

OnClose ( ) : void

Closes the appender and releases resources.

Releases any resources allocated within the appender such as file handles, network connections, etc.

It is a programming error to append to a closed appender.

Method Details

AddAppender() public method

Adds an IAppender to the list of appenders of this instance.

If the specified IAppender is already in the list of appenders, then it won't be added again.

public AddAppender ( IAppender newAppender ) : void
newAppender IAppender The to add to this appender.
return void

Append() protected method

Forward the logging event to the attached appenders

Delivers the logging event to all the attached appenders.

protected Append ( log4net.Core.LoggingEvent loggingEvent ) : void
loggingEvent log4net.Core.LoggingEvent The event to log.
return void

GetAppender() public method

Looks for the appender with the specified name.

Get the named appender attached to this appender.

public GetAppender ( string name ) : IAppender
name string The name of the appender to lookup.
return IAppender

OnClose() protected method

Closes the appender and releases resources.

Releases any resources allocated within the appender such as file handles, network connections, etc.

It is a programming error to append to a closed appender.

protected OnClose ( ) : void
return void

RemoveAllAppenders() public method

Removes all previously added appenders from this appender.

This is useful when re-reading configuration information.

public RemoveAllAppenders ( ) : void
return void

RemoveAppender() public method

Removes the specified appender from the list of appenders.
The appender removed is not closed. If you are discarding the appender you must call IAppender.Close on the appender removed.
public RemoveAppender ( IAppender appender ) : IAppender
appender IAppender The appender to remove.
return IAppender

RemoveAppender() public method

Removes the appender with the specified name from the list of appenders.
The appender removed is not closed. If you are discarding the appender you must call IAppender.Close on the appender removed.
public RemoveAppender ( string name ) : IAppender
name string The name of the appender to remove.
return IAppender

RenderingForwardingAppender() public method

Initializes a new instance of the ForwardingAppender class.

Default constructor.

public RenderingForwardingAppender ( ) : System
return System