C# Class CK.Core.ActivityMonitorErrorCounter

Count fatal, error or warn that occurred. It can also automatically adds a conclusion to closed groups that summarizes the number of fatals, errors and warnings.
Inheritance: ActivityMonitorClient, IActivityMonitorBoundClient
Datei anzeigen Open project: Invenietis/ck-core Class Usage Examples

Public Properties

Property Type Description
TagErrorCounter CKTrait

Public Methods

Method Description
ActivityMonitorErrorCounter ( bool generateConclusion = false ) : System

Initializes a new error counter with GenerateConclusion sets to false.

Protected Methods

Method Description
OnGroupClosed ( IActivityLogGroup group, IReadOnlyList conclusions ) : void

Restores current to the previous one (or keep it on the root if no opened group exist).

OnGroupClosing ( IActivityLogGroup group, List &conclusions ) : void

Handles group conclusion.

OnOpenGroup ( IActivityLogGroup group ) : void

Updates error counters.

OnUnfilteredLog ( ActivityMonitorLogData data ) : void

Updates error counters.

Private Methods

Method Description
IActivityMonitorBoundClient ( IActivityMonitorImpl source, bool forceBuggyRemove ) : void

Method Details

ActivityMonitorErrorCounter() public method

Initializes a new error counter with GenerateConclusion sets to false.
public ActivityMonitorErrorCounter ( bool generateConclusion = false ) : System
generateConclusion bool True to generate a conclusion. See .
return System

OnGroupClosed() protected method

Restores current to the previous one (or keep it on the root if no opened group exist).
protected OnGroupClosed ( IActivityLogGroup group, IReadOnlyList conclusions ) : void
group IActivityLogGroup The log group.
conclusions IReadOnlyList Texts that conclude the group.
return void

OnGroupClosing() protected method

Handles group conclusion.
protected OnGroupClosing ( IActivityLogGroup group, List &conclusions ) : void
group IActivityLogGroup The closing group.
conclusions List /// Mutable conclusions associated to the closing group. /// This can be null if no conclusions have been added yet. /// It is up to the first client that wants to add a conclusion to instantiate a new List object to carry the conclusions. ///
return void

OnOpenGroup() protected method

Updates error counters.
protected OnOpenGroup ( IActivityLogGroup group ) : void
group IActivityLogGroup The newly opened .
return void

OnUnfilteredLog() protected method

Updates error counters.
protected OnUnfilteredLog ( ActivityMonitorLogData data ) : void
data ActivityMonitorLogData Log data. Never null.
return void

Property Details

TagErrorCounter public_oe static_oe property

Gets the tag used for generated error conclusions ("c:ErrorCounter") when GenerateConclusion is true.
public static CKTrait TagErrorCounter
return CKTrait