seconds | Seconds to wait for. |
cancellationToken | Optional cancellation token. |
Resumes execution after the specified number of seconds.
Can be safely awaited multiple times in the same method, as shown in the example below. For more information, refer to Awaitable code example reference in the Manual.
async Awaitable Foo(){ await Awaitable.WaitForSecondsAsync(2); // Do something await Awaitable.WaitForSecondsAsync(2); // Do something else }