C# Class CK.Core.ActivityMonitorLogData

Data required by IActivityMonitor.UnfilteredLog. This is also the base class for ActivityMonitorGroupData.
ファイルを表示 Open project: Invenietis/ck-core Class Usage Examples

Public Properties

Property Type Description
FileName string
Level LogLevel
LineNumber int
MaskedLevel LogLevel

Public Methods

Method Description
ActivityMonitorLogData ( LogLevel level, Exception exception, CKTrait tags, string text, DateTimeStamp logTime, string fileName, int lineNumber ) : System

Initializes a new ActivityMonitorLogData.

ActivityMonitorLogData ( LogLevel level, string fileName, int lineNumber ) : System

Preinitializes a new ActivityMonitorLogData: Initialize has yet to be called.

EnsureExceptionData ( ) : CKExceptionData

Gets or creates the CKExceptionData that captures exception information. If P:Exception is null, this returns null.

Initialize ( string text, Exception exception, CKTrait tags, DateTimeStamp logTime ) : void

Initializes this data.

Private Methods

Method Description
ActivityMonitorLogData ( ) : System

Used only to initialize a ActivityMonitorGroupSender for rejected opened group.

CombineTagsAndAdjustLogTime ( CKTrait tags, DateTimeStamp lastLogTime ) : DateTimeStamp

Method Details

ActivityMonitorLogData() public method

Initializes a new ActivityMonitorLogData.
public ActivityMonitorLogData ( LogLevel level, Exception exception, CKTrait tags, string text, DateTimeStamp logTime, string fileName, int lineNumber ) : System
level LogLevel Log level. Can not be .
exception System.Exception Exception of the log. Can be null.
tags CKTrait Tags (from ) to associate to the log. It will be union-ed with the current .
text string Text of the log. Can be null or empty only if is not null: the is the text.
logTime DateTimeStamp /// Time of the log. /// You can use or IActivityMonitor.NextLogTime() extension method. ///
fileName string Name of the source file that emitted the log. Can be null.
lineNumber int Line number in the source file that emitted the log. Can be null.
return System

ActivityMonitorLogData() public method

Preinitializes a new ActivityMonitorLogData: Initialize has yet to be called.
public ActivityMonitorLogData ( LogLevel level, string fileName, int lineNumber ) : System
level LogLevel Log level. Can not be .
fileName string Name of the source file that emitted the log. Can be null.
lineNumber int Line number in the source file that emitted the log. Can be null.
return System

EnsureExceptionData() public method

Gets or creates the CKExceptionData that captures exception information. If P:Exception is null, this returns null.
public EnsureExceptionData ( ) : CKExceptionData
return CKExceptionData

Initialize() public method

Initializes this data.
public Initialize ( string text, Exception exception, CKTrait tags, DateTimeStamp logTime ) : void
text string /// Text of the log. Can be null or empty: if is not null, /// the becomes the text otherwise is used. ///
exception System.Exception Exception of the log. Can be null.
tags CKTrait /// Tags (from ) to associate to the log. /// It will be union-ed with the current .
logTime DateTimeStamp /// Time of the log. /// You can use or IActivityMonitor.NextLogTime() extension method. ///
return void

Property Details

FileName public_oe property

Name of the source file that emitted the log. Can be null.
public string FileName
return string

Level public_oe property

Log level. Can not be LogLevel.None. If the log has been successfully filtered, the LogLevel.IsFiltered bit flag is set.
public LogLevel Level
return LogLevel

LineNumber public_oe property

Line number in the source file that emitted the log. Can be null.
public int LineNumber
return int

MaskedLevel public_oe property

The actual level (LogLevel.Trace to LogLevel.Fatal) associated to this group without LogLevel.IsFiltered bit flag.
public LogLevel MaskedLevel
return LogLevel