RunFunctionTaskBase< T > Class Template Reference

RunFunctionTaskBase< T > Class Template Referenceabstract

#include <qtconcurrentrunbase.h>

Class Description

template<typename T>
class QtConcurrent::RunFunctionTaskBase< T >

Definition at line 77 of file qtconcurrentrunbase.h.

+ Inheritance diagram for RunFunctionTaskBase< T >:

Public Member Functions

QFuture< T > start ()
 
void run ()
 
virtual void runFunctor ()=0
 
- Public Member Functions inherited from QFutureInterface< T >
 QFutureInterface (State initialState=NoState)
 
 QFutureInterface (const QFutureInterface &other)
 
 ~QFutureInterface ()
 
QFutureInterfaceoperator= (const QFutureInterface &other)
 
QFuture< T > future ()
 
void reportResult (const T *result, int index=-1)
 
void reportResult (const T &result, int index=-1)
 
void reportResults (const QVector< T > &results, int beginIndex=-1, int count=-1)
 
void reportFinished (const T *result=0)
 
const T & resultReference (int index) const
 
const T * resultPointer (int index) const
 
QList< T > results ()
 
- Public Member Functions inherited from QFutureInterfaceBase
 QFutureInterfaceBase (State initialState=NoState)
 
 QFutureInterfaceBase (const QFutureInterfaceBase &other)
 
virtual ~QFutureInterfaceBase ()
 
void reportStarted ()
 
void reportFinished ()
 
void reportCanceled ()
 
void reportException (const QtConcurrent::Exception &e)
 
void reportResultsReady (int beginIndex, int endIndex)
 
void setRunnable (QRunnable *runnable)
 
void setFilterMode (bool enable)
 
void setProgressRange (int minimum, int maximum)
 
int progressMinimum () const
 
int progressMaximum () const
 
bool isProgressUpdateNeeded () const
 
void setProgressValue (int progressValue)
 
int progressValue () const
 
void setProgressValueAndText (int progressValue, const QString &progressText)
 
QString progressText () const
 
void setExpectedResultCount (int resultCount)
 
int expectedResultCount ()
 
int resultCount () const
 
bool queryState (State state) const
 
bool isRunning () const
 
bool isStarted () const
 
bool isCanceled () const
 
bool isFinished () const
 
bool isPaused () const
 
bool isThrottled () const
 
bool isResultReadyAt (int index) const
 
void cancel ()
 
void setPaused (bool paused)
 
void togglePaused ()
 
void setThrottled (bool enable)
 
void waitForFinished ()
 
bool waitForNextResult ()
 
void waitForResult (int resultIndex)
 
void waitForResume ()
 
QMutexmutex () const
 
QtConcurrent::internal::ExceptionStoreexceptionStore ()
 
QtConcurrent::ResultStoreBaseresultStoreBase ()
 
const QtConcurrent::ResultStoreBaseresultStoreBase () const
 
bool operator== (const QFutureInterfaceBase &other) const
 
bool operator!= (const QFutureInterfaceBase &other) const
 
QFutureInterfaceBaseoperator= (const QFutureInterfaceBase &other)
 
- Public Member Functions inherited from QRunnable
 QRunnable ()
 
virtual ~QRunnable ()
 
bool autoDelete () const
 
void setAutoDelete (bool _autoDelete)
 

Additional Inherited Members

- Public Types inherited from QFutureInterfaceBase
enum  State {
  NoState = 0x00, Running = 0x01, Started = 0x02, Finished = 0x04,
  Canceled = 0x08, Paused = 0x10, Throttled = 0x20
}
 
- Static Public Member Functions inherited from QFutureInterface< T >
static QFutureInterface canceledResult ()
 
- Protected Member Functions inherited from QFutureInterfaceBase
bool referenceCountIsOne () const
 

Member Function Documentation

QFuture<T> start ( )
inline

Definition at line 80 of file qtconcurrentrunbase.h.

81  {
82  this->setRunnable(this);
83  this->reportStarted();
84  QFuture<T> future = this->future();
85  QThreadPool::globalInstance()->start(this, /*m_priority*/ 0);
86  return future;
87  }
void start(QRunnable *runnable, int priority=0)
void setRunnable(QRunnable *runnable)
static QThreadPool * globalInstance()
QFuture< T > future()
Definition: qfuture.h:186
void run ( )
inlinevirtual

Implements QRunnable.

Reimplemented in RunFunctionTask< T >.

Definition at line 89 of file qtconcurrentrunbase.h.

89 {}
virtual void runFunctor ( )
pure virtual

Implemented in StoredFunctorCall< void, Functor >, StoredFunctorCall< T, Functor >, VoidStoredConstMemberFunctionPointerCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, StoredConstMemberFunctionPointerCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, VoidStoredMemberFunctionPointerCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, StoredMemberFunctionPointerCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, VoidStoredConstMemberFunctionCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, StoredConstMemberFunctionCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, VoidStoredMemberFunctionCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, StoredMemberFunctionCall5< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4, Param5, Arg5 >, VoidStoredFunctorPointerCall5< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4, Arg5 >, StoredFunctorPointerCall5< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4, Arg5 >, StoredFunctorCall5< void, FunctionPointer, Arg1, Arg2, Arg3, Arg4, Arg5 >, StoredFunctorCall5< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4, Arg5 >, VoidStoredConstMemberFunctionPointerCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, StoredConstMemberFunctionPointerCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, VoidStoredMemberFunctionPointerCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, StoredMemberFunctionPointerCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, VoidStoredConstMemberFunctionCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, StoredConstMemberFunctionCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, VoidStoredMemberFunctionCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, StoredMemberFunctionCall4< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3, Param4, Arg4 >, VoidStoredFunctorPointerCall4< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4 >, StoredFunctorPointerCall4< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4 >, StoredFunctorCall4< void, FunctionPointer, Arg1, Arg2, Arg3, Arg4 >, StoredFunctorCall4< T, FunctionPointer, Arg1, Arg2, Arg3, Arg4 >, VoidStoredConstMemberFunctionPointerCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, StoredConstMemberFunctionPointerCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, VoidStoredMemberFunctionPointerCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, StoredMemberFunctionPointerCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, VoidStoredConstMemberFunctionCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, StoredConstMemberFunctionCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, VoidStoredMemberFunctionCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, StoredMemberFunctionCall3< T, Class, Param1, Arg1, Param2, Arg2, Param3, Arg3 >, VoidStoredFunctorPointerCall3< T, FunctionPointer, Arg1, Arg2, Arg3 >, StoredFunctorPointerCall3< T, FunctionPointer, Arg1, Arg2, Arg3 >, StoredFunctorCall3< void, FunctionPointer, Arg1, Arg2, Arg3 >, StoredFunctorCall3< T, FunctionPointer, Arg1, Arg2, Arg3 >, VoidStoredConstMemberFunctionPointerCall2< T, Class, Param1, Arg1, Param2, Arg2 >, StoredConstMemberFunctionPointerCall2< T, Class, Param1, Arg1, Param2, Arg2 >, VoidStoredMemberFunctionPointerCall2< T, Class, Param1, Arg1, Param2, Arg2 >, StoredMemberFunctionPointerCall2< T, Class, Param1, Arg1, Param2, Arg2 >, VoidStoredConstMemberFunctionCall2< T, Class, Param1, Arg1, Param2, Arg2 >, StoredConstMemberFunctionCall2< T, Class, Param1, Arg1, Param2, Arg2 >, VoidStoredMemberFunctionCall2< T, Class, Param1, Arg1, Param2, Arg2 >, StoredMemberFunctionCall2< T, Class, Param1, Arg1, Param2, Arg2 >, VoidStoredFunctorPointerCall2< T, FunctionPointer, Arg1, Arg2 >, StoredFunctorPointerCall2< T, FunctionPointer, Arg1, Arg2 >, StoredFunctorCall2< void, FunctionPointer, Arg1, Arg2 >, StoredFunctorCall2< T, FunctionPointer, Arg1, Arg2 >, VoidStoredConstMemberFunctionPointerCall1< T, Class, Param1, Arg1 >, StoredConstMemberFunctionPointerCall1< T, Class, Param1, Arg1 >, VoidStoredMemberFunctionPointerCall1< T, Class, Param1, Arg1 >, StoredMemberFunctionPointerCall1< T, Class, Param1, Arg1 >, VoidStoredConstMemberFunctionCall1< T, Class, Param1, Arg1 >, StoredConstMemberFunctionCall1< T, Class, Param1, Arg1 >, VoidStoredMemberFunctionCall1< T, Class, Param1, Arg1 >, StoredMemberFunctionCall1< T, Class, Param1, Arg1 >, VoidStoredFunctorPointerCall1< T, FunctionPointer, Arg1 >, StoredFunctorPointerCall1< T, FunctionPointer, Arg1 >, StoredFunctorCall1< void, FunctionPointer, Arg1 >, StoredFunctorCall1< T, FunctionPointer, Arg1 >, VoidStoredConstMemberFunctionPointerCall0< T, Class >, StoredConstMemberFunctionPointerCall0< T, Class >, VoidStoredMemberFunctionPointerCall0< T, Class >, StoredMemberFunctionPointerCall0< T, Class >, VoidStoredConstMemberFunctionCall0< T, Class >, StoredConstMemberFunctionCall0< T, Class >, VoidStoredMemberFunctionCall0< T, Class >, StoredMemberFunctionCall0< T, Class >, VoidStoredFunctorPointerCall0< T, FunctionPointer >, StoredFunctorPointerCall0< T, FunctionPointer >, StoredFunctorCall0< void, FunctionPointer >, and StoredFunctorCall0< T, FunctionPointer >.


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