Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QtPrivate::Continuation< Function, ResultType, ParentResultType > Class Template Referenceabstract

#include <qfuture_impl.h>

+ Inheritance diagram for QtPrivate::Continuation< Function, ResultType, ParentResultType >:
+ Collaboration diagram for QtPrivate::Continuation< Function, ResultType, ParentResultType >:

Public Member Functions

template<typename F = Function>
 Continuation (F &&func, const QFuture< ParentResultType > &f, QPromise< ResultType > &&p)
 
virtual ~Continuation ()=default
 
bool execute ()
 

Static Public Member Functions

template<typename F = Function>
static void create (F &&func, QFuture< ParentResultType > *f, QFutureInterface< ResultType > &fi, QtFuture::Launch policy)
 
template<typename F = Function>
static void create (F &&func, QFuture< ParentResultType > *f, QFutureInterface< ResultType > &fi, QThreadPool *pool)
 
template<typename F = Function>
static void create (F &&func, QFuture< ParentResultType > *f, QFutureInterface< ResultType > &fi, QObject *context)
 

Protected Member Functions

virtual void runImpl ()=0
 
void runFunction ()
 

Protected Attributes

QPromise< ResultType > promise
 
QFuture< ParentResultType > parentFuture
 
Function function
 

Detailed Description

template<typename Function, typename ResultType, typename ParentResultType>
class QtPrivate::Continuation< Function, ResultType, ParentResultType >

Definition at line 288 of file qfuture_impl.h.

Constructor & Destructor Documentation

◆ Continuation()

template<typename Function , typename ResultType , typename ParentResultType >
template<typename F = Function>
QtPrivate::Continuation< Function, ResultType, ParentResultType >::Continuation ( F && func,
const QFuture< ParentResultType > & f,
QPromise< ResultType > && p )
inline

Definition at line 293 of file qfuture_impl.h.

◆ ~Continuation()

template<typename Function , typename ResultType , typename ParentResultType >
virtual QtPrivate::Continuation< Function, ResultType, ParentResultType >::~Continuation ( )
virtualdefault

Member Function Documentation

◆ create() [1/3]

template<typename Function , typename ResultType , typename ParentResultType >
template<typename F >
void QtPrivate::Continuation< Function, ResultType, ParentResultType >::create ( F && func,
QFuture< ParentResultType > * f,
QFutureInterface< ResultType > & fi,
QObject * context )
static

Definition at line 603 of file qfuture_impl.h.

References context, Q_ASSERT, and QtPrivate::watchContinuation().

+ Here is the call graph for this function:

◆ create() [2/3]

template<typename Function , typename ResultType , typename ParentResultType >
template<typename F >
void QtPrivate::Continuation< Function, ResultType, ParentResultType >::create ( F && func,
QFuture< ParentResultType > * f,
QFutureInterface< ResultType > & fi,
QtFuture::Launch policy )
static

Definition at line 516 of file qfuture_impl.h.

References QtFuture::Async, QtFuture::Inherit, policy, pool, and Q_ASSERT.

◆ create() [3/3]

template<typename Function , typename ResultType , typename ParentResultType >
template<typename F >
void QtPrivate::Continuation< Function, ResultType, ParentResultType >::create ( F && func,
QFuture< ParentResultType > * f,
QFutureInterface< ResultType > & fi,
QThreadPool * pool )
static

Definition at line 566 of file qfuture_impl.h.

References pool, and Q_ASSERT.

◆ execute()

template<typename Function , typename ResultType , typename ParentResultType >
bool QtPrivate::Continuation< Function, ResultType, ParentResultType >::execute ( )

Definition at line 464 of file qfuture_impl.h.

References Q_ASSERT.

◆ runFunction()

template<typename Function , typename ResultType , typename ParentResultType >
void QtPrivate::Continuation< Function, ResultType, ParentResultType >::runFunction ( )
protected

Definition at line 418 of file qfuture_impl.h.

References QtPrivate::fulfillPromise(), function, and Q_ASSERT.

Referenced by QtPrivate::AsyncContinuation< Function, ResultType, ParentResultType >::run(), and QtPrivate::SyncContinuation< Function, ResultType, ParentResultType >::runImpl().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ runImpl()

template<typename Function , typename ResultType , typename ParentResultType >
virtual void QtPrivate::Continuation< Function, ResultType, ParentResultType >::runImpl ( )
protectedpure virtual

Member Data Documentation

◆ function

template<typename Function , typename ResultType , typename ParentResultType >
Function QtPrivate::Continuation< Function, ResultType, ParentResultType >::function
protected

Definition at line 329 of file qfuture_impl.h.

◆ parentFuture

template<typename Function , typename ResultType , typename ParentResultType >
QFuture<ParentResultType> QtPrivate::Continuation< Function, ResultType, ParentResultType >::parentFuture
protected

Definition at line 328 of file qfuture_impl.h.

◆ promise

template<typename Function , typename ResultType , typename ParentResultType >
QPromise<ResultType> QtPrivate::Continuation< Function, ResultType, ParentResultType >::promise
protected

Definition at line 327 of file qfuture_impl.h.


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