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
QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer > Class Template Reference

\inmodule QtConcurrent More...

#include <qtconcurrentfilterkernel.h>

+ Inheritance diagram for QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >:
+ Collaboration diagram for QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >:

Public Types

typedef ReducedResultType ReturnType
 
typedef ReducedResultType ResultType
 
- Public Types inherited from QtConcurrent::IterateKernel< Iterator, ReducedResultType >
typedef ReducedResultType ResultType
 
- Public Types inherited from QtConcurrent::ThreadEngine< T >
typedef T ResultType
 
- Public Types inherited from QRunnable
template<typename Callable >
using if_callable = std::enable_if_t<std::is_invocable_r_v<void, Callable>, bool>
 

Public Member Functions

template<typename Keep = KeepFunctor, typename Reduce = ReduceFunctor>
 FilteredReducedKernel (QThreadPool *pool, Iterator begin, Iterator end, Keep &&_keep, Reduce &&_reduce, ReduceOptions reduceOption)
 
template<typename Keep = KeepFunctor, typename Reduce = ReduceFunctor>
 FilteredReducedKernel (QThreadPool *pool, Iterator begin, Iterator end, Keep &&_keep, Reduce &&_reduce, ReducedResultType &&initialValue, ReduceOptions reduceOption)
 
bool runIteration (Iterator it, int index, ReducedResultType *) override
 
bool runIterations (Iterator sequenceBeginIterator, int begin, int end, ReducedResultType *) override
 
void finish () override
 
bool shouldThrottleThread () override
 
bool shouldStartThread () override
 
ReducedResultType * result () override
 
- Public Member Functions inherited from QtConcurrent::IterateKernel< Iterator, ReducedResultType >
 IterateKernel (QThreadPool *pool, Iterator _begin, Iterator _end)
 
 IterateKernel (QThreadPool *pool, Iterator _begin, Iterator _end)
 
 IterateKernel (QThreadPool *pool, Iterator _begin, Iterator _end, U &&_defaultValue)
 
virtual ~IterateKernel ()
 
void start () override
 
bool shouldStartThread () override
 
ThreadFunctionResult threadFunction () override
 
ThreadFunctionResult forThreadFunction ()
 
ThreadFunctionResult whileThreadFunction ()
 
- Public Member Functions inherited from QtConcurrent::ThreadEngine< T >
 ThreadEngine (QThreadPool *pool)
 
QFutureInterface< T > * futureInterfaceTyped ()
 
T * startSingleThreaded ()
 
QFuture< T > startAsynchronously ()
 
void asynchronousFinish () override
 
void reportResult (const T *_result, int index=-1)
 
void reportResults (const QList< T > &_result, int index=-1, int count=-1)
 
- Public Member Functions inherited from QtConcurrent::ThreadEngineBase
 ThreadEngineBase (QThreadPool *pool)
 
virtual ~ThreadEngineBase ()
 
void startSingleThreaded ()
 
void startThread ()
 
bool isCanceled ()
 
void waitForResume ()
 
bool isProgressReportingEnabled ()
 
void setProgressValue (int progress)
 
void setProgressRange (int minimum, int maximum)
 
void acquireBarrierSemaphore ()
 
void reportIfSuspensionDone () const
 
- Public Member Functions inherited from QRunnable
constexpr QRunnable () noexcept=default
 Constructs a QRunnable.
 
virtual ~QRunnable ()
 QRunnable virtual destructor.
 
bool autoDelete () const
 Returns true is auto-deletion is enabled; false otherwise.
 
void setAutoDelete (bool autoDelete)
 Enables auto-deletion if autoDelete is true; otherwise auto-deletion is disabled.
 
template<typename Callable , if_callable< Callable > = true>
 QGenericRunnable (Callable &&c)
 
 ~QGenericRunnable () override
 
void run () override
 

Additional Inherited Members

- Static Public Member Functions inherited from QRunnable
template<typename Callable , if_callable< Callable > = true>
static QRunnablecreate (Callable &&functionToRun)
 
static QRunnablecreate (std::nullptr_t)=delete
 
- Public Attributes inherited from QtConcurrent::IterateKernel< Iterator, ReducedResultType >
const Iterator begin
 
const Iterator end
 
Iterator current
 
QAtomicInt currentIndex
 
QAtomicInt iteratorThreads
 
QAtomicInt completed
 
const int iterationCount
 
const bool forIteration
 
bool progressReportingEnabled
 
DefaultValueContainer< ResultTypedefaultValue
 
- Protected Attributes inherited from QtConcurrent::ThreadEngineBase
QFutureInterfaceBasefutureInterface
 
QThreadPoolthreadPool
 
ThreadEngineBarrier barrier
 
QtPrivate::ExceptionStore exceptionStore
 
QBasicMutex mutex
 

Detailed Description

template<typename ReducedResultType, typename Iterator, typename KeepFunctor, typename ReduceFunctor, typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
class QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >

\inmodule QtConcurrent

Definition at line 125 of file qtconcurrentfilterkernel.h.

Member Typedef Documentation

◆ ResultType

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
typedef ReducedResultType QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::ResultType

Definition at line 204 of file qtconcurrentfilterkernel.h.

◆ ReturnType

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
typedef ReducedResultType QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::ReturnType

Definition at line 203 of file qtconcurrentfilterkernel.h.

Constructor & Destructor Documentation

◆ FilteredReducedKernel() [1/2]

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
template<typename Keep = KeepFunctor, typename Reduce = ReduceFunctor>
QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::FilteredReducedKernel ( QThreadPool * pool,
Iterator begin,
Iterator end,
Keep && _keep,
Reduce && _reduce,
ReduceOptions reduceOption )
inline

Definition at line 135 of file qtconcurrentfilterkernel.h.

◆ FilteredReducedKernel() [2/2]

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
template<typename Keep = KeepFunctor, typename Reduce = ReduceFunctor>
QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::FilteredReducedKernel ( QThreadPool * pool,
Iterator begin,
Iterator end,
Keep && _keep,
Reduce && _reduce,
ReducedResultType && initialValue,
ReduceOptions reduceOption )
inline

Definition at line 145 of file qtconcurrentfilterkernel.h.

Member Function Documentation

◆ finish()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
void QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::finish ( )
inlineoverridevirtual

Reimplemented from QtConcurrent::ThreadEngineBase.

Definition at line 188 of file qtconcurrentfilterkernel.h.

◆ result()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
ReducedResultType * QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::result ( )
inlineoverridevirtual

Reimplemented from QtConcurrent::ThreadEngine< T >.

Definition at line 205 of file qtconcurrentfilterkernel.h.

◆ runIteration()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
bool QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::runIteration ( Iterator it,
int index,
ReducedResultType *  )
inlineoverridevirtual

Reimplemented from QtConcurrent::IterateKernel< Iterator, ReducedResultType >.

Definition at line 156 of file qtconcurrentfilterkernel.h.

References QList< T >::append(), QList< T >::begin(), QList< T >::end(), it, and results.

+ Here is the call graph for this function:

◆ runIterations()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
bool QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::runIterations ( Iterator sequenceBeginIterator,
int begin,
int end,
ReducedResultType *  )
inlineoverridevirtual

Reimplemented from QtConcurrent::IterateKernel< Iterator, ReducedResultType >.

Definition at line 169 of file qtconcurrentfilterkernel.h.

References QList< T >::append(), QtConcurrent::IterateKernel< Iterator, ReducedResultType >::begin, QList< T >::begin(), QtConcurrent::IterateKernel< Iterator, ReducedResultType >::end, QList< T >::end(), i, it, QList< T >::reserve(), and results.

+ Here is the call graph for this function:

◆ shouldStartThread()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
bool QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::shouldStartThread ( )
inlineoverridevirtual

Reimplemented from QtConcurrent::ThreadEngineBase.

Definition at line 198 of file qtconcurrentfilterkernel.h.

References QtConcurrent::IterateKernel< Iterator, ReducedResultType >::shouldStartThread().

+ Here is the call graph for this function:

◆ shouldThrottleThread()

template<typename ReducedResultType , typename Iterator , typename KeepFunctor , typename ReduceFunctor , typename Reducer = ReduceKernel<ReduceFunctor, ReducedResultType, typename qValueType<Iterator>::value_type>>
bool QtConcurrent::FilteredReducedKernel< ReducedResultType, Iterator, KeepFunctor, ReduceFunctor, Reducer >::shouldThrottleThread ( )
inlineoverridevirtual

Reimplemented from QtConcurrent::ThreadEngineBase.

Definition at line 193 of file qtconcurrentfilterkernel.h.

References QtConcurrent::ThreadEngineBase::shouldThrottleThread().

+ Here is the call graph for this function:

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