Chombo + EB + MF  3.2
Public Member Functions | Protected Attributes | List of all members
CoDimCopyManager< T > Class Template Reference

Helper class to manage CoDim exchange operations. More...

#include <CoDimCopyManager.H>

Public Member Functions

 CoDimCopyManager ()
 null constructor More...
 
 CoDimCopyManager (const DisjointBoxLayout &a_grids, const BoxLayout &a_dest, const IntVect &a_ghostVect, bool a_exchange=false, int a_maxCoDim=SpaceDim)
 defining constructor – calls matching define function More...
 
 ~CoDimCopyManager ()
 destructor More...
 
void define (const DisjointBoxLayout &a_grids, const BoxLayout &a_dest, const IntVect &a_ghostVect, bool a_exchange=false, int a_maxCoDim=SpaceDim)
 define More...
 
void manageExchanges (LevelData< T > &a_data) const
 orchestrates CoDim exchanges More...
 
void manageCopies (const LevelData< T > &a_data, BoxLayoutData< T > &a_dest) const
 orchestrates CoDim copies More...
 
IntVect ghostVect () const
 returns ghostVect used to define this object (to check for compatibility) More...
 
const DisjointBoxLayoutsrcGrids () const
 returns reference to src layout used to define this object More...
 
const BoxLayoutdestGrids () const
 returns reference to dest layout used to define this object More...
 

Protected Attributes

Vector< Copier * > m_copierVect
 Vector of CoDimCopiers. More...
 
IntVect m_ghostVect
 keep ghostVect around just in case More...
 
DisjointBoxLayout m_srcGrids
 keep source and dest layouts around as well More...
 
BoxLayout m_destGrids
 

Detailed Description

template<class T>
class CoDimCopyManager< T >

Helper class to manage CoDim exchange operations.

CoDimCopiers are designed to be exercised in order, starting with CoDim=2 and increasing to SpaceDim. The CoDimCopyManager class manages these operations.

Constructor & Destructor Documentation

template<class T >
CoDimCopyManager< T >::CoDimCopyManager ( )
inline

null constructor

template<class T >
CoDimCopyManager< T >::CoDimCopyManager ( const DisjointBoxLayout a_grids,
const BoxLayout a_dest,
const IntVect a_ghostVect,
bool  a_exchange = false,
int  a_maxCoDim = SpaceDim 
)

defining constructor – calls matching define function

by default, does all coDim copies from CoDim=2->SpaceDim. If you know you only need coDim ghost cells up to a Co-dimension less than SpaceDim, that can be specified, which will make things cheaper.

template<class T >
CoDimCopyManager< T >::~CoDimCopyManager ( )

destructor

clean up memory

Member Function Documentation

template<class T >
void CoDimCopyManager< T >::define ( const DisjointBoxLayout a_grids,
const BoxLayout a_dest,
const IntVect a_ghostVect,
bool  a_exchange = false,
int  a_maxCoDim = SpaceDim 
)

define

References CH_assert, and DisjointBoxLayout::physDomain().

template<class T >
void CoDimCopyManager< T >::manageExchanges ( LevelData< T > &  a_data) const

orchestrates CoDim exchanges

References LevelData< T >::exchange().

template<class T >
void CoDimCopyManager< T >::manageCopies ( const LevelData< T > &  a_data,
BoxLayoutData< T > &  a_dest 
) const

orchestrates CoDim copies

References LevelData< T >::copyTo().

template<class T >
IntVect CoDimCopyManager< T >::ghostVect ( ) const
inline

returns ghostVect used to define this object (to check for compatibility)

References CoDimCopyManager< T >::m_ghostVect.

template<class T >
const DisjointBoxLayout& CoDimCopyManager< T >::srcGrids ( ) const
inline

returns reference to src layout used to define this object

References CoDimCopyManager< T >::m_srcGrids.

template<class T >
const BoxLayout& CoDimCopyManager< T >::destGrids ( ) const
inline

returns reference to dest layout used to define this object

References CoDimCopyManager< T >::m_destGrids.

Member Data Documentation

template<class T >
Vector<Copier*> CoDimCopyManager< T >::m_copierVect
protected

Vector of CoDimCopiers.

template<class T >
IntVect CoDimCopyManager< T >::m_ghostVect
protected

keep ghostVect around just in case

Referenced by CoDimCopyManager< T >::ghostVect().

template<class T >
DisjointBoxLayout CoDimCopyManager< T >::m_srcGrids
protected

keep source and dest layouts around as well

Referenced by CoDimCopyManager< T >::srcGrids().

template<class T >
BoxLayout CoDimCopyManager< T >::m_destGrids
protected

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