DelayedTaskDelay Method (TimeSpan) |
Creates a task that will complete after a time delay.
Namespace: Rackspace.ThreadingAssembly: Rackspace.Threading (in Rackspace.Threading.dll) Version: 2.1.0-beta1
Syntax
public static Task Delay(
TimeSpan delay
)
Public Shared Function Delay (
delay As TimeSpan
) As Task
public:
static Task^ Delay(
TimeSpan delay
)
static member Delay :
delay : TimeSpan -> Task
Parameters
- delay
- Type: SystemTimeSpan
The time span to wait before completing the returned task
Return Value
Type:
TaskA task that represents the time delay
Exceptions Remarks
After the specified time delay, the task is completed in RanToCompletion
state.
This method ignores any fractional milliseconds when evaluating delay.
Version Information
.NET for Windows Store apps
Supported in: Windows 8
.NET Framework
Supported in: 4.5, 4.0, 3.5
Portable Class Library
Supported in: Portable Class Library (Legacy), Portable Class Library
Threading Library
Supported in: 2.1, 2.0, 1.1
See Also