libpromeki main
PROfessional MEdia toolKIt
 
Loading...
Searching...
No Matches
Promise< void > Class Reference

Specialization of Promise for void results. More...

#include <promise.h>

Public Member Functions

 Promise ()=default
 Constructs a Promise.
 
 ~Promise ()=default
 Destructor.
 
 Promise (const Promise &)=delete
 
Promiseoperator= (const Promise &)=delete
 
 Promise (Promise &&other)=default
 
Promiseoperator= (Promise &&other)=default
 
void setValue ()
 Signals completion (no value).
 
void setError (Error error)
 Sets an error on the promise.
 
Future< voidfuture ()
 Returns the Future associated with this Promise.
 

Detailed Description

Specialization of Promise for void results.

Member Function Documentation

◆ future()

Future< void > Promise< void >::future ( )
inline

Returns the Future associated with this Promise.

Returns
A Future<void> that will receive the completion signal.

◆ setError()

void Promise< void >::setError ( Error  error)
inline

Sets an error on the promise.

Parameters
errorThe error to set.

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