AMDiS 2.10
The Adaptive Multi-Dimensional Simulation Toolbox
VectorBase< Derived > Class Template Reference

CRTP base class for flat vector backends. More...

#include <VectorBase.hpp>

Public Member Functions

void finish ()
 
void synchronize ()
 
template<class MultiIndex , class ValueType , class Assign >
void insert (MultiIndex const &idx, ValueType const &value, Assign assign)
 Insert or add value at position idx, using the passed assign functor.
 
template<class IndexRange , class OutputIterator >
void gather (IndexRange const &localInd, OutputIterator buffer) const
 Gather values from the vector into the output range buffer decribed as an output iterator.
 
template<class IndexRange , class LocalVec , class Assign >
void scatter (IndexRange const &localInd, LocalVec const &vec, FakeContainer< bool, true >, Assign assign)
 Scatter the values from the local vec into the container using the passed assign functor.
 
template<class IndexRange , class LocalVec , class MaskRange , class Assign >
void scatter (IndexRange const &localInd, LocalVec const &vec, MaskRange const &mask, Assign assign)
 
template<class IndexRange , class Func >
void forEach (IndexRange const &localInd, Func &&f) const
 Apply the functor f to all entries of the list of multi-indices localInd.
 
template<class IndexRange , class Func >
void forEach (IndexRange const &localInd, Func &&f)
 Apply the functor f to all entries of the list of multi-indices localInd.
 

Protected Member Functions

 VectorBase ()=default
 

Detailed Description

template<class Derived>
class AMDiS::VectorBase< Derived >

CRTP base class for flat vector backends.

Constructor & Destructor Documentation

◆ VectorBase()

VectorBase ( )
protecteddefault

Protected constructor prevents from direct construction of this class. Only use it as base class in the sense of CRTP.

Member Function Documentation

◆ scatter()

void scatter ( IndexRange const &  localInd,
LocalVec const &  vec,
MaskRange const &  mask,
Assign  assign 
)
inline

Scatter some values from the local vec into the container using the passed assign functor. The values to scatter are selected using the mask range that needs to be forward iterable.


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