OpenMPCD
Public Member Functions | List of all members
OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor Class Reference

Functor class for advancing a pointer by the given number of effective elements. More...

#include <BunchIteratorRange.hpp>

Inheritance diagram for OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor:
Inheritance graph
[legend]
Collaboration diagram for OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor:
Collaboration graph
[legend]

Public Member Functions

OPENMPCD_CUDA_HOST_AND_DEVICE AdvancingFunctor (const unsigned int bunchSize_, const unsigned int gapSize_)
 The constructor. More...
 
const OPENMPCD_CUDA_HOST_AND_DEVICE IteratorDifference operator() (const IteratorDifference &i) const
 Calculates how many times the underlying iterator has to be incremented to achieve i increments of the effective iterator. More...
 

Detailed Description

template<typename UnderlyingIterator>
class OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor

Functor class for advancing a pointer by the given number of effective elements.

Definition at line 52 of file BunchIteratorRange.hpp.

Constructor & Destructor Documentation

◆ AdvancingFunctor()

template<typename UnderlyingIterator >
OPENMPCD_CUDA_HOST_AND_DEVICE OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor::AdvancingFunctor ( const unsigned int  bunchSize_,
const unsigned int  gapSize_ 
)
inline

The constructor.

Exceptions
OpenMPCD::InvalidArgumentExceptionIf OPENMPCD_DEBUG is defined, throws if bunchSize_ == 0.
Parameters
[in]bunchSize_The bunch size, which must not be 0.
[in]gapSize_The gap size.

Definition at line 67 of file BunchIteratorRange.hpp.

Member Function Documentation

◆ operator()()

template<typename UnderlyingIterator >
const OPENMPCD_CUDA_HOST_AND_DEVICE IteratorDifference OpenMPCD::CUDA::BunchIteratorRange< UnderlyingIterator >::AdvancingFunctor::operator() ( const IteratorDifference i) const
inline

Calculates how many times the underlying iterator has to be incremented to achieve i increments of the effective iterator.

Parameters
[in]iThe number of times the effective iterator is to be incremented.

Definition at line 84 of file BunchIteratorRange.hpp.


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