Interface ITask
Defines a task that can be concurrently executed by scheduling agent.
Namespace: Nevatech.Vsb.Agent
Assembly: Nevatech.Vsb.Agent.dll
Syntax
public interface ITask : IValidator, IDisposableProperties
IsStarted
Gets the flag that indicates that task is successfully started.
Declaration
bool IsStarted { get; }Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
Name
Gets or sets the name of the task.
Declaration
string Name { get; set; }Property Value
| Type | Description | 
|---|---|
| System.String | 
Methods
OnStart(HostType)
Initializes and starts the task.
Declaration
void OnStart(HostType hostType)Parameters
| Type | Name | Description | 
|---|---|---|
| HostType | hostType | The type of host process where task is running. | 
Remarks
Method implementation should start timer, subscribe to system events, or create a working thread and return immediately.
OnStop()
Stops task and releases its resources.
Declaration
void OnStop()