Dune::cpgrid::PointViaCellHandleWrapper< Handle > Struct Template Reference

A data handle to send data attached to points via cell communication. More...

#include <DataHandleWrappers.hpp>

Inheritance diagram for Dune::cpgrid::PointViaCellHandleWrapper< Handle >:
Inheritance graph

Public Types

using DataType = typename Handle::DataType
 
using C2PTable = std::vector< std::array< int, 8 > >
 

Public Member Functions

 PointViaCellHandleWrapper (Handle &handle, const C2PTable &c2pGather, const C2PTable &c2p)
 Constructs the data handle. More...
 
bool fixedSize (int i, int j)
 
template<class T >
std::enable_if< T::codimension!=0, std::size_t >::type size (const T &)
 
std::size_t size (const EntityRep< 0 > &t)
 
bool contains (std::size_t dim, std::size_t codim)
 
template<class B , class T >
std::enable_if< T::codimension!=0, void >::type gather (B &, const T &)
 
template<class B >
void gather (B &buffer, const EntityRep< 0 > &t)
 
template<class B , class T >
std::enable_if< T::codimension!=0, void >::type scatter (B &, const T &, std::size_t)
 
template<class B >
void scatter (B &buffer, const EntityRep< 0 > &t, std::size_t s)
 
void warn ()
 

Static Public Attributes

static bool printWarn
 

Detailed Description

template<class Handle>
struct Dune::cpgrid::PointViaCellHandleWrapper< Handle >

A data handle to send data attached to points via cell communication.

With it we can use the cell communication to also communicate data attached to faces.

Warning
As we send all points of cell most of the points will be send six times which will temporarily waste some space and bandwidth.
Template Parameters
HandleThe type of the data handle to wrap. It must gather and scatter only for codim-3 entities.

Member Typedef Documentation

◆ C2PTable

template<class Handle >
using Dune::cpgrid::PointViaCellHandleWrapper< Handle >::C2PTable = std::vector< std::array<int,8> >

◆ DataType

template<class Handle >
using Dune::cpgrid::PointViaCellHandleWrapper< Handle >::DataType = typename Handle::DataType

Constructor & Destructor Documentation

◆ PointViaCellHandleWrapper()

template<class Handle >
Dune::cpgrid::PointViaCellHandleWrapper< Handle >::PointViaCellHandleWrapper ( Handle &  handle,
const C2PTable c2pGather,
const C2PTable c2p 
)
inline

Constructs the data handle.

Parameters
handleHandle object wrapped and used for actual gather/scatter
c2pGatherTable to determine points when gathering
c2pTable to determine points when scattering

Member Function Documentation

◆ contains()

template<class Handle >
bool Dune::cpgrid::PointViaCellHandleWrapper< Handle >::contains ( std::size_t  dim,
std::size_t  codim 
)
inline

◆ fixedSize()

template<class Handle >
bool Dune::cpgrid::PointViaCellHandleWrapper< Handle >::fixedSize ( int  i,
int  j 
)
inline

◆ gather() [1/2]

template<class Handle >
template<class B , class T >
std::enable_if< T::codimension!=0, void >::type Dune::cpgrid::PointViaCellHandleWrapper< Handle >::gather ( B &  ,
const T &   
)
inline

◆ gather() [2/2]

template<class Handle >
template<class B >
void Dune::cpgrid::PointViaCellHandleWrapper< Handle >::gather ( B &  buffer,
const EntityRep< 0 > &  t 
)
inline

◆ scatter() [1/2]

template<class Handle >
template<class B , class T >
std::enable_if< T::codimension!=0, void >::type Dune::cpgrid::PointViaCellHandleWrapper< Handle >::scatter ( B &  ,
const T &  ,
std::size_t   
)
inline

◆ scatter() [2/2]

template<class Handle >
template<class B >
void Dune::cpgrid::PointViaCellHandleWrapper< Handle >::scatter ( B &  buffer,
const EntityRep< 0 > &  t,
std::size_t  s 
)
inline

◆ size() [1/2]

template<class Handle >
std::size_t Dune::cpgrid::PointViaCellHandleWrapper< Handle >::size ( const EntityRep< 0 > &  t)
inline

◆ size() [2/2]

template<class Handle >
template<class T >
std::enable_if< T::codimension!=0, std::size_t >::type Dune::cpgrid::PointViaCellHandleWrapper< Handle >::size ( const T &  )
inline

◆ warn()

void Dune::cpgrid::PointViaCellWarner::warn ( )
inherited

Member Data Documentation

◆ printWarn

bool Dune::cpgrid::PointViaCellWarner::printWarn
staticinherited

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