cutelyst 5.0.1
A C++ Web Framework built on top of Qt, using the simple approach of Catalyst (Perl) framework.
Cutelyst::CoroContext::promise_type Struct Reference

Public Member Functions

template<typename... ArgTypes>
 promise_type (Cutelyst::Context *context, ArgTypes &&...)
template<typename... ArgTypes>
 promise_type (QObject &obj, Cutelyst::Context *context, ArgTypes &&...)
bool await_ready () const noexcept
void await_resume () const noexcept
void await_suspend (std::coroutine_handle<> h) noexcept
void clean ()
std::suspend_never final_suspend () noexcept
CoroContext get_return_object ()
std::suspend_never initial_suspend () const noexcept
void return_void () noexcept
void trackContext (Context *context)
void unhandled_exception ()
std::suspend_never yield_value (const QObject *obj)
std::suspend_never yield_value (Cutelyst::Context *context)

Public Attributes

std::vector< QMetaObject::Connectionconnections
std::coroutine_handle< promise_type > handle

Detailed Description

Definition at line 38 of file CoroContext.h.

Constructor & Destructor Documentation

◆ promise_type() [1/2]

template<typename... ArgTypes>
Cutelyst::CoroContext::promise_type::promise_type ( QObject & obj,
Cutelyst::Context * context,
ArgTypes && ... )
inline

Definition at line 91 of file CoroContext.h.

◆ promise_type() [2/2]

template<typename... ArgTypes>
Cutelyst::CoroContext::promise_type::promise_type ( Cutelyst::Context * context,
ArgTypes && ... )
inlineexplicit

Definition at line 98 of file CoroContext.h.

◆ ~promise_type()

Cutelyst::CoroContext::promise_type::~promise_type ( )
inline

Definition at line 125 of file CoroContext.h.

Member Function Documentation

◆ await_ready()

bool Cutelyst::CoroContext::promise_type::await_ready ( ) const
inlinenoexcept

Definition at line 62 of file CoroContext.h.

◆ await_resume()

void Cutelyst::CoroContext::promise_type::await_resume ( ) const
inlinenoexcept

Definition at line 64 of file CoroContext.h.

◆ await_suspend()

void Cutelyst::CoroContext::promise_type::await_suspend ( std::coroutine_handle<> h)
inlinenoexcept

Definition at line 63 of file CoroContext.h.

◆ clean()

void Cutelyst::CoroContext::promise_type::clean ( )
inline

Definition at line 42 of file CoroContext.h.

◆ final_suspend()

std::suspend_never Cutelyst::CoroContext::promise_type::final_suspend ( )
inlinenoexcept

Definition at line 59 of file CoroContext.h.

◆ get_return_object()

CoroContext Cutelyst::CoroContext::promise_type::get_return_object ( )
inline

Definition at line 52 of file CoroContext.h.

◆ initial_suspend()

std::suspend_never Cutelyst::CoroContext::promise_type::initial_suspend ( ) const
inlinenoexcept

Definition at line 58 of file CoroContext.h.

◆ return_void()

void Cutelyst::CoroContext::promise_type::return_void ( )
inlinenoexcept

Definition at line 50 of file CoroContext.h.

◆ trackContext()

void Cutelyst::CoroContext::promise_type::trackContext ( Context * context)
inline

Definition at line 103 of file CoroContext.h.

◆ unhandled_exception()

void Cutelyst::CoroContext::promise_type::unhandled_exception ( )
inline

Definition at line 60 of file CoroContext.h.

◆ yield_value() [1/2]

std::suspend_never Cutelyst::CoroContext::promise_type::yield_value ( const QObject * obj)
inline

Definition at line 69 of file CoroContext.h.

◆ yield_value() [2/2]

std::suspend_never Cutelyst::CoroContext::promise_type::yield_value ( Cutelyst::Context * context)
inline

Definition at line 82 of file CoroContext.h.

Member Data Documentation

◆ connections

std::vector<QMetaObject::Connection> Cutelyst::CoroContext::promise_type::connections

Definition at line 40 of file CoroContext.h.

◆ handle

std::coroutine_handle<promise_type> Cutelyst::CoroContext::promise_type::handle

Definition at line 39 of file CoroContext.h.