Uni20
Asynchronous tensor and runtime library.
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
uni20::async::TaskFactoryAwaiter< A > Struct Template Reference

Forwarding awaiter that transfers shared task ownership through a TaskFactory. More...

#include <async_task_promise.hpp>

Collaboration diagram for uni20::async::TaskFactoryAwaiter< A >:
[legend]

Public Member Functions

bool await_ready ()
 Checks whether the wrapped awaitable is ready.
 
decltype(auto) await_resume ()
 Resume wrapped awaitable and return its await result.
 
template<TaskPromise Promise>
void await_suspend (std::coroutine_handle< Promise > handle)
 Suspend using shared-ownership await-suspend semantics.
 

Public Attributes

A awaitable
 
TaskPromiseBase & promise
 

Detailed Description

template<TaskFactoryAwaitable A>
struct uni20::async::TaskFactoryAwaiter< A >

Forwarding awaiter that transfers shared task ownership through a TaskFactory.

Member Function Documentation

◆ await_ready()

template<TaskFactoryAwaitable A>
bool uni20::async::TaskFactoryAwaiter< A >::await_ready ( )
inline

Checks whether the wrapped awaitable is ready.

Returns
true when no suspension is needed.

◆ await_resume()

template<TaskFactoryAwaitable A>
decltype(auto) uni20::async::TaskFactoryAwaiter< A >::await_resume ( )
inline

Resume wrapped awaitable and return its await result.

Returns
Result produced by the wrapped awaitable.

◆ await_suspend()

template<TaskFactoryAwaitable A>
template<TaskPromise Promise>
void uni20::async::TaskFactoryAwaiter< A >::await_suspend ( std::coroutine_handle< Promise >  handle)
inline

Suspend using shared-ownership await-suspend semantics.

Template Parameters
PromiseConcrete enclosing promise type.
Parameters
handleCurrent coroutine handle.

Member Data Documentation

◆ awaitable

template<TaskFactoryAwaitable A>
A uni20::async::TaskFactoryAwaiter< A >::awaitable

◆ promise

template<TaskFactoryAwaitable A>
TaskPromiseBase& uni20::async::TaskFactoryAwaiter< A >::promise

The documentation for this struct was generated from the following file: