C# Class CK.Monitoring.GrandOutputHandlers.HandlerBase

Base class to handle of GrandOutputEventInfo. Specialized handlers are configured by an associated HandlerConfiguration specialization.
Inheritance: IGrandOutputSink
Show file Open project: Invenietis/ck-core Class Usage Examples

Public Methods

Method Description
Close ( IActivityMonitor monitor ) : void

Closes this handler. This is called when a reconfiguration occurs after all events have been Handled. Default implementation does nothing.

CollectChannelOption ( ChannelOption option ) : void

Enables this handler to interact with any channel to which it belongs. This is called after Initialize and for each channel where this handler appears, before the first call to Handle. Default implementation must be called: sets the minimal filter on the option if the HandlerConfiguration defines it.

Handle ( GrandOutputEventInfo logEvent, bool parrallelCall ) : void

Handles a GrandOutputEventInfo.

Initialize ( IActivityMonitor monitor ) : void

Initializes this handler. This is called once for all the configured sink at the start of a new configuration, before the first call to Handle. Default implementation does nothing.

Protected Methods

Method Description
HandlerBase ( HandlerConfiguration config ) : CK.Core

Base constructor bound to base configuration object.

Private Methods

Method Description
HandlerBase ( CK config ) : CK.Core

Internal constructor used by Sequence and Parallel.

Method Details

Close() public method

Closes this handler. This is called when a reconfiguration occurs after all events have been Handled. Default implementation does nothing.
public Close ( IActivityMonitor monitor ) : void
monitor IActivityMonitor The monitor that tracks configuration process.
return void

CollectChannelOption() public method

Enables this handler to interact with any channel to which it belongs. This is called after Initialize and for each channel where this handler appears, before the first call to Handle. Default implementation must be called: sets the minimal filter on the option if the HandlerConfiguration defines it.
public CollectChannelOption ( ChannelOption option ) : void
option ChannelOption
return void

Handle() public abstract method

Handles a GrandOutputEventInfo.
public abstract Handle ( GrandOutputEventInfo logEvent, bool parrallelCall ) : void
logEvent GrandOutputEventInfo Event to handle.
parrallelCall bool True when this method is called in parallel with other handlers.
return void

HandlerBase() protected method

Base constructor bound to base configuration object.
protected HandlerBase ( HandlerConfiguration config ) : CK.Core
config HandlerConfiguration The configuration object.
return CK.Core

Initialize() public method

Initializes this handler. This is called once for all the configured sink at the start of a new configuration, before the first call to Handle. Default implementation does nothing.
public Initialize ( IActivityMonitor monitor ) : void
monitor IActivityMonitor The monitor that tracks configuration process.
return void