C# Class Oda.Log

Writes a log. Safe for multi threaded writes.
Inheritance: IDisposable
显示文件 Open project: CorbinDallas/Oda

Public Methods

Method Description
Dispose ( ) : void

Disposes this instance.

Log ( string logPath, int verbosity, bool includeTimestamp ) : System

Initializes a new instance of the Log class.

WriteLine ( string dataToLog ) : void

Write a line to the log.

WriteLine ( string dataToLog, int verbosity ) : void

Write a line to the log.

Protected Methods

Method Description
Dispose ( bool managed ) : void

Releases unmanaged and - optionally - managed resources.

Private Methods

Method Description
StartLogWriter ( ) : void

Starts the log writer thread.

Method Details

Dispose() public method

Disposes this instance.
public Dispose ( ) : void
return void

Dispose() protected method

Releases unmanaged and - optionally - managed resources.
protected Dispose ( bool managed ) : void
managed bool true to release both managed and unmanaged resources; false to release only unmanaged resources.
return void

Log() public method

Initializes a new instance of the Log class.
public Log ( string logPath, int verbosity, bool includeTimestamp ) : System
logPath string
verbosity int
includeTimestamp bool
return System

WriteLine() public method

Write a line to the log.
public WriteLine ( string dataToLog ) : void
dataToLog string The data to log.
return void

WriteLine() public method

Write a line to the log.
public WriteLine ( string dataToLog, int verbosity ) : void
dataToLog string The data to log.
verbosity int The verbosity level of this message. Low numbers show up sooner than high numbers.
return void