userver: engine::Promise< void > Class Reference
Loading...
Searching...
No Matches
engine::Promise< void > Class Referencefinal

Detailed Description

Definition at line 162 of file future.hpp.

Public Member Functions

 Promise ()
 Creates a new asynchronous signal store.
 
 Promise (const Promise &)=delete
 
 Promise (Promise &&) noexcept=default
 
Promiseoperator= (const Promise &)=delete
 
Promiseoperator= (Promise &&) noexcept
 
Future< void > get_future ()
 
void set_value ()
 
void set_exception (std::exception_ptr ex)
 

Constructor & Destructor Documentation

◆ Promise()

engine::Promise< void >::Promise ( )
inline

Creates a new asynchronous signal store.

Definition at line 286 of file future.hpp.

◆ ~Promise()

engine::Promise< void >::~Promise ( )
inline

Definition at line 295 of file future.hpp.

Member Function Documentation

◆ get_future()

Future< void > engine::Promise< void >::get_future ( )
inline

Retrieves the Future associated with this signal store.

Exceptions
std::future_errorif the Future has already been retrieved.

Definition at line 305 of file future.hpp.

◆ set_exception()

void engine::Promise< void >::set_exception ( std::exception_ptr ex)
inline

Stores an exception to be thrown on retrieval.

Exceptions
std::future_errorif a signal or an exception has already been set.

Definition at line 309 of file future.hpp.

◆ set_value()

void engine::Promise< void >::set_value ( )
inline

Stores a signal for retrieval.

Exceptions
std::future_errorif a signal or an exception has already been set.

Definition at line 307 of file future.hpp.


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