WhenAny()
Contents
[
Hide
]System::Threading::Tasks::WhenAny(const SharedPtr<Collections::Generic::IEnumerable<TaskPtr>>&) function
Creates a task that will complete when any of the supplied tasks have completed.
RTaskPtr<TaskPtr> System::Threading::Tasks::WhenAny(const SharedPtr<Collections::Generic::IEnumerable<TaskPtr>> &tasks)
Arguments
| Parameter | Type | Description |
|---|---|---|
| tasks | const SharedPtr<Collections::Generic::IEnumerable<TaskPtr>>& | The tasks to wait on for completion. |
Return Value
A task that represents the completion of one of the supplied tasks.
System::Threading::Tasks::WhenAny(const ArrayPtr<TaskPtr>&) function
Creates a task that will complete when any of the supplied tasks have completed.
RTaskPtr<TaskPtr> System::Threading::Tasks::WhenAny(const ArrayPtr<TaskPtr> &tasks)
Arguments
| Parameter | Type | Description |
|---|---|---|
| tasks | const ArrayPtr<TaskPtr>& | The tasks to wait on for completion. |
Return Value
A task that represents the completion of one of the supplied tasks.
System::Threading::Tasks::WhenAny(const ArrayPtr<RTaskPtr<TResult>>&) function
Creates a task that will complete when any of the supplied tasks have completed.
template<typename TResult> RTaskPtr<RTaskPtr<TResult>> System::Threading::Tasks::WhenAny(const ArrayPtr<RTaskPtr<TResult>> &tasks)
Template parameters
| Parameter | Description |
|---|---|
| TResult | The type of the completed task’s result. |
Arguments
| Parameter | Type | Description |
|---|---|---|
| tasks | const ArrayPtr<RTaskPtr<TResult>>& | The tasks to wait on for completion. |
Return Value
A task that returns the first completed task when any task completes.
System::Threading::Tasks::WhenAny(const SharedPtr<Collections::Generic::IEnumerable<RTaskPtr<TResult>>>&) function
Creates a task that will complete when any of the supplied tasks have completed.
template<typename TResult> RTaskPtr<RTaskPtr<TResult>> System::Threading::Tasks::WhenAny(const SharedPtr<Collections::Generic::IEnumerable<RTaskPtr<TResult>>> &tasks)
Template parameters
| Parameter | Description |
|---|---|
| TResult | The type of the completed task’s result. |
Arguments
| Parameter | Type | Description |
|---|---|---|
| tasks | const SharedPtr<Collections::Generic::IEnumerable<RTaskPtr<TResult>>>& | The tasks to wait on for completion. |
Return Value
A task that returns the first completed task when any task completes.
See Also
- Typedef RTaskPtr
- Typedef TaskPtr
- Typedef SharedPtr
- Typedef ArrayPtr
- Class IEnumerable
- Namespace System::Threading::Tasks
- Library Aspose.Slides