Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Experimental > API/Runtime/Core/Experimental/Async
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Experimental/Async/AwaitableTask.h |
| Include | #include "Experimental/Async/AwaitableTask.h" |
Syntax
template<typename ReturnType>
class TAwaitableTask
Remarks
Awaitable Tasks are very simple they only allow for Lauching and Awaiting a Task. They will try to run other work while awaiting the Result.
Constructors
| Type | Name | Description | |
|---|---|---|---|
TAwaitableTask
(
const ThisClass& Other |
|||
TAwaitableTask
(
ThisClass&& Other |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| ReturnType | Await () |
Await the Task Completion and get the result, this will assert if this is a Dummy Handle. | |
| void | Busy wait until the Task is launched from another Thread, this can be useful if we want to build chained tasks. | ||
| void | Init
(
const TCHAR* DebugName, |
Initialize a new Task with given Priority now and Abandon previous work (if any) initialized Tasks can be awaited on, but they will run synchronous in this case | |
| void | Initialize a new Task now and Abandon previous work (if any) initialized Tasks can be awaited on, but they will run synchronous in this case | ||
| bool | InitAndLaunch
(
const TCHAR* DebugName, |
Initialize and Launch a Task | |
| bool | InitAndLaunch
(
const TCHAR* DebugName, |
Initialize and Launch a Task with given Priority | |
| bool | IsCompleted () |
Returns true if the Tasks completed. | |
| bool | IsLaunched () |
Returns true if the Task has been Launched. | |
| bool | IsValid () |
Does the TaskHandle hold a valid or Dummy Task? | |
| void | Reset () |
Abandon the Task and freeing its memory if this is the last reference to it. | |
| bool | TryLaunch () |
Launches the Task for processing on a WorkerThread. The returntype will specify if the Task was Launched successfully (true) or if it might have been launched already (false) |
Operators
Typedefs
| Name | Description |
|---|---|
| ThisClass | |
| TPromise | |
| TPromiseVTable | |
| TPromiseVTableBase | |
| TPromiseVTableDummy |