C# Class Platform.TaskUtils

Provides extension methods and static utility methods for ITasks objects.
Exibir arquivo Open project: platformdotnet/Platform

Public Methods

Method Description
WaitForAnyTaskState ( this task, System.TimeSpan timeout ) : bool

Waits for a task to reach one or more given states

WaitForAnyTaskState ( this task, System.TimeSpan timeout, Predicate acceptState ) : bool

Waits for a task to reach a given state

WaitForAnyTaskState ( this task ) : void

Waits for a task to reach one or more given states

WaitForAnyTaskState ( this task, Predicate acceptState ) : void

Waits for a task to reach a given state

WaitForFinish ( this task ) : void

Method Details

WaitForAnyTaskState() public static method

Waits for a task to reach one or more given states
public static WaitForAnyTaskState ( this task, System.TimeSpan timeout ) : bool
task this The task to wait on
timeout System.TimeSpan A timeout
return bool

WaitForAnyTaskState() public static method

Waits for a task to reach a given state
public static WaitForAnyTaskState ( this task, System.TimeSpan timeout, Predicate acceptState ) : bool
task this The task to wait on
timeout System.TimeSpan A timeout
acceptState Predicate A predicate that validates for a given state
return bool

WaitForAnyTaskState() public static method

Waits for a task to reach one or more given states
public static WaitForAnyTaskState ( this task ) : void
task this The task to wait on
return void

WaitForAnyTaskState() public static method

Waits for a task to reach a given state
public static WaitForAnyTaskState ( this task, Predicate acceptState ) : void
task this The task to wait on
acceptState Predicate A predicate that validates for a given state
return void

WaitForFinish() public static method

public static WaitForFinish ( this task ) : void
task this
return void