Loading...
Searching...
No Matches
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
bitpit::LevelSetCachedKernel Interface Reference

Base class for defining kernels that need to cache data. More...

Inheritance diagram for bitpit::LevelSetCachedKernel:
Inheritance graph
[legend]
Collaboration diagram for bitpit::LevelSetCachedKernel:
Collaboration graph
[legend]

Public Types

typedef ElementCacheCollection CellCacheCollection
 

Public Member Functions

 LevelSetCachedKernel (VolumeKernel *, LevelSetFillIn fillIn)
 
void clearCaches (bool release=false)
 
bool update (const std::vector< adaption::Info > &) override
 
- Public Member Functions inherited from bitpit::LevelSetKernel
 LevelSetKernel ()
 
 LevelSetKernel (VolumeKernel *mesh, LevelSetFillIn fillIn)
 
virtual ~LevelSetKernel ()
 
virtual double computeCellBoundingRadius (long) const =0
 
virtual std::array< double, 3 > computeCellCentroid (long) const =0
 
virtual double computeCellTangentRadius (long) const =0
 
std::unique_ptr< DataCommunicatorcreateDataCommunicator () const
 
MPI_Comm getCommunicator () const
 
double getDistanceTolerance () const
 
LevelSetFillIn getExpectedFillIn () const
 
virtual VolumeKernelgetMesh () const
 
virtual bool intersectCellPlane (long, const std::array< double, 3 > &, const std::array< double, 3 > &, double)
 
double isCellInsideBoundingBox (long, const std::array< double BITPIT_COMMA 3 > &, const std::array< double, 3 > &) const
 
bool isCommunicatorSet () const
 
bool isPointInCell (long, const std::array< double, 3 > &) const
 

Protected Member Functions

CellCacheCollectiongetCellCacheCollection ()
 
const CellCacheCollectiongetCellCacheCollection () const
 

Protected Attributes

std::unique_ptr< CellCacheCollectionm_cellCacheCollection
 
- Protected Attributes inherited from bitpit::LevelSetKernel
MPI_Comm m_communicator
 
LevelSetFillIn m_expectedFillIn
 
VolumeKernelm_mesh
 

Detailed Description

Base class for defining kernels that need to cache data.

Definition at line 94 of file levelSetKernel.hpp.

Member Typedef Documentation

◆ CellCacheCollection

Definition at line 97 of file levelSetKernel.hpp.

Constructor & Destructor Documentation

◆ LevelSetCachedKernel()

bitpit::LevelSetCachedKernel::LevelSetCachedKernel ( VolumeKernel * patch,
LevelSetFillIn fillIn )

Constructor

Parameters
[in]patchunderlying mesh
[in]fillInexpected kernel fill-in

Definition at line 297 of file levelSetKernel.cpp.

Member Function Documentation

◆ clearCaches()

void bitpit::LevelSetCachedKernel::clearCaches ( bool release = false)

Clear the cache used for caching mesh information.

Parameters
releaseif set to true the memory hold by the cache will be released, otherwise the cache will be cleared but its memory may not be released

Definition at line 309 of file levelSetKernel.cpp.

◆ getCellCacheCollection() [1/2]

LevelSetCachedKernel::CellCacheCollection & bitpit::LevelSetCachedKernel::getCellCacheCollection ( )
protected

Get a reference to the cell cache collection.

Attempting to access cache collection when cache is disabled results in undefined behavior.

Returns
A reference to the cell cache collection.

Definition at line 331 of file levelSetKernel.cpp.

◆ getCellCacheCollection() [2/2]

const LevelSetCachedKernel::CellCacheCollection & bitpit::LevelSetCachedKernel::getCellCacheCollection ( ) const
protected

Get a constant reference to the cell cache collection.

Attempting to access cache collection when cache is disabled results in undefined behavior.

Returns
A constant reference to the cell cache collection.

Definition at line 343 of file levelSetKernel.cpp.

◆ update()

bool bitpit::LevelSetCachedKernel::update ( const std::vector< adaption::Info > & adaptionData)
overridevirtual

Updates the kernel after an adaption.

Parameters
[in]adaptionDataare the information about the adaption
Returns
Returns true if the kernel has been updated, false if no update was needed.

Implements bitpit::LevelSetKernel.

Definition at line 354 of file levelSetKernel.cpp.

Member Data Documentation

◆ m_cellCacheCollection

std::unique_ptr<CellCacheCollection> bitpit::LevelSetCachedKernel::m_cellCacheCollection
mutableprotected

Cell cache collection

Definition at line 106 of file levelSetKernel.hpp.


The documentation for this interface was generated from the following files:
--- layout: doxygen_footer ---