- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Directories
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions

# MappedEachKernel< Iterator, MapFunctor > Class Template Reference

Search for all occurrences

## Detailed Description

### template<typename Iterator, typename MapFunctor>
class QtConcurrent::MappedEachKernel< Iterator, MapFunctor >

Definition at line 167 of file qtconcurrentmapkernel.h.

`#include <qtconcurrentmapkernel.h>`

Inheritance diagram for MappedEachKernel< Iterator, MapFunctor >:
[legend]

List of all members.

## Public Types
typedef T | ReturnType
typedef T | ResultType
## Public Member Functions
| MappedEachKernel (Iterator begin, Iterator end, MapFunctor _map)
bool | runIteration (Iterator it, int, T *result)
bool | runIterations (Iterator sequenceBeginIterator, int begin, int end, T *results)

## Member Typedef Documentation

typedef T ReturnType

Search for all occurrences

Definition at line 172 of file qtconcurrentmapkernel.h.

typedef T ResultType

Search for all occurrences

Reimplemented from IterateKernel< Iterator, MapFunctor::result_type >.

Definition at line 173 of file qtconcurrentmapkernel.h.

## Constructor & Destructor Documentation

MappedEachKernel | ( | Iterator | begin,
|  | Iterator | end,
|  | MapFunctor | _map
| ) |  | `[inline]`

Definition at line 175 of file qtconcurrentmapkernel.h.

            : IterateKernel<Iterator, T>(begin, end), map(_map) { }

## Member Function Documentation

bool runIteration | ( | Iterator | it,
|  | int | ,
|  | T * | result
| ) |  | `[inline, virtual]`

Search for all occurrences

Reimplemented from IterateKernel< Iterator, MapFunctor::result_type >.

Definition at line 178 of file qtconcurrentmapkernel.h.

        {
            *result = map(*it);
            return true;
        }

bool runIterations | ( | Iterator | sequenceBeginIterator,
|  | int | begin,
|  | int | end,
|  | T * | results
| ) |  | `[inline, virtual]`

Search for all occurrences

Reimplemented from IterateKernel< Iterator, MapFunctor::result_type >.

Definition at line 184 of file qtconcurrentmapkernel.h.

        {

            Iterator it = sequenceBeginIterator;
            advance(it, begin);
            for (int i = begin; i < end; ++i) {
                runIteration(it, i, results + (i - begin));
                advance(it, 1);
            }

            return true;
        }

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

- QtCore/qtconcurrentmapkernel.h