Table of Contents

Interface IJobResultProducer<T>

Namespace
Tlabs.JobCntrl.Model
Assembly
Tlabs.JobCntrl.dll

Interface of an object that lets a Job produce an result for that a consumer can wait.

public interface IJobResultProducer<T>

Type Parameters

T
Extension Methods

Properties

HasResult

True if a result has been produced.

bool HasResult { get; }

Property Value

bool

Remarks

if this reurn true, a subsequent call to GetResult() would return a result immediately.

Methods

GetResult()

Returns a produced result.

T GetResult()

Returns

T

Remarks

Blocks until a result has been produced.

GetResult(int)

Returns a result produced.

T GetResult(int timeOut)

Parameters

timeOut int

Max. number of milliseconds to wait for a result.

Returns

T

Remarks

Blocks until a result has been produced or timed-out.

Exceptions

TimeoutException

Exception thrown when timeOut milliseconds elapsed w/o resilt.

Produce(T)

Produce a result to be returned from GetResult().

void Produce(T result)

Parameters

result T