C# Class CodeSharp.EventSourcing.WorkerThread

Represents a worker thread that will repeatedly execute a callback.
Show file Open project: tangxuehua/eventsourcing Class Usage Examples

Public Methods

Method Description
Start ( ) : void

Starts the worker thread.

Stop ( ) : void

Stops the worker thread.

WorkerThread ( System methodToRunInLoop ) : System

Initializes a new WorkerThread for the specified method to run.

Protected Methods

Method Description
Loop ( ) : void

Executes the delegate method until the Stop method is called.

Method Details

Loop() protected method

Executes the delegate method until the Stop method is called.
protected Loop ( ) : void
return void

Start() public method

Starts the worker thread.
public Start ( ) : void
return void

Stop() public method

Stops the worker thread.
public Stop ( ) : void
return void

WorkerThread() public method

Initializes a new WorkerThread for the specified method to run.
public WorkerThread ( System methodToRunInLoop ) : System
methodToRunInLoop System The delegate method to execute in a loop.
return System