Nugget
Loading...
Searching...
No Matches
Public Member Functions | Friends | List of all members
psyqo::Coroutine< T >::Awaiter Struct Reference

The awaiter type. More...

#include <psyqo/coroutine.hh>

Public Member Functions

 Awaiter (Awaiter &&other)=default
 
Awaiteroperator= (Awaiter &&other)=default
 
 Awaiter (Awaiter const &)=default
 
Awaiteroperator= (Awaiter const &)=default
 
constexpr bool await_ready () const noexcept
 
constexpr void await_suspend (std::coroutine_handle<> h)
 
constexpr void await_resume () const noexcept
 

Friends

struct Coroutine
 

Detailed Description

template<typename T = void>
struct psyqo::Coroutine< T >::Awaiter

The awaiter type.

The awaiter type is the type that is used to suspend the coroutine after scheduling an asychronous operation. The keyword co_await can be used on an instance of the object to suspend the current coroutine. Creating an instance of this object is done by calling coroutine.awaiter().

Constructor & Destructor Documentation

◆ Awaiter() [1/2]

template<typename T = void>
psyqo::Coroutine< T >::Awaiter::Awaiter ( Awaiter &&  other)
default

◆ Awaiter() [2/2]

template<typename T = void>
psyqo::Coroutine< T >::Awaiter::Awaiter ( Awaiter const &  )
default

Member Function Documentation

◆ await_ready()

template<typename T = void>
constexpr bool psyqo::Coroutine< T >::Awaiter::await_ready ( ) const
inlineconstexprnoexcept

◆ await_resume()

template<typename T = void>
constexpr void psyqo::Coroutine< T >::Awaiter::await_resume ( ) const
inlineconstexprnoexcept

◆ await_suspend()

template<typename T = void>
constexpr void psyqo::Coroutine< T >::Awaiter::await_suspend ( std::coroutine_handle<>  h)
inlineconstexpr

◆ operator=() [1/2]

template<typename T = void>
Awaiter & psyqo::Coroutine< T >::Awaiter::operator= ( Awaiter &&  other)
default

◆ operator=() [2/2]

template<typename T = void>
Awaiter & psyqo::Coroutine< T >::Awaiter::operator= ( Awaiter const &  )
default

Friends And Related Symbol Documentation

◆ Coroutine

template<typename T = void>
friend struct Coroutine
friend

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