Loading...
Searching...
No Matches
Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Friends | List of all members
bitpit::SkdPatchInfo Class Reference

The SkdPatchInfo class allows to store patch information needed for the construction and the utilization of a skd-tree. More...

Collaboration diagram for bitpit::SkdPatchInfo:
Collaboration graph
[legend]

Public Member Functions

void buildCache ()
 
void buildCache (const PatchKernel::CellConstRange &cellRange)
 
void destroyCache ()
 
std::array< double, 3 > evalCachedBoxMean (std::size_t rawId) const
 
double evalCachedBoxMean (std::size_t rawId, int direction) const
 
const std::array< std::array< double, 3 >, 2 > & getCachedBox (std::size_t rawId) const
 
std::size_t getCellRawId (std::size_t n) const
 
const std::vector< std::size_t > & getCellRawIds () const
 
const PatchKernelgetPatch () const
 

Protected Types

typedef PiercedStorage< std::array< std::array< double, 3 >, 2 >, long > BoxCache
 

Protected Member Functions

 SkdPatchInfo (const PatchKernel *patch, const std::vector< std::size_t > *cellRawIds)
 

Protected Attributes

std::unique_ptr< BoxCachem_cellBoxes
 
const std::vector< std::size_t > * m_cellRawIds
 
const PatchKernelm_patch
 

Friends

class PatchSkdTree
 

Detailed Description

The SkdPatchInfo class allows to store patch information needed for the construction and the utilization of a skd-tree.

Definition at line 36 of file patch_skd_tree.hpp.

Member Typedef Documentation

◆ BoxCache

typedef PiercedStorage<std::array<std::array<double, 3>, 2>, long> bitpit::SkdPatchInfo::BoxCache
protected

Definition at line 55 of file patch_skd_tree.hpp.

Constructor & Destructor Documentation

◆ SkdPatchInfo()

bitpit::SkdPatchInfo::SkdPatchInfo ( const PatchKernel * patch,
const std::vector< std::size_t > * cellRawIds )
protected

Constructor.

Parameters
patchis the patch
cellRawIdsis the list of cell raw ids

Definition at line 47 of file patch_skd_tree.cpp.

Member Function Documentation

◆ buildCache() [1/2]

void bitpit::SkdPatchInfo::buildCache ( )

Build the cache.

Definition at line 58 of file patch_skd_tree.cpp.

◆ buildCache() [2/2]

void bitpit::SkdPatchInfo::buildCache ( const PatchKernel::CellConstRange & cellRange)

Build the cache.

Parameters
cellRangeis the range of cells fow which the cache has to be built

Definition at line 70 of file patch_skd_tree.cpp.

◆ destroyCache()

void bitpit::SkdPatchInfo::destroyCache ( )

Destroy the cache.

Definition at line 85 of file patch_skd_tree.cpp.

◆ evalCachedBoxMean() [1/2]

std::array< double, 3 > bitpit::SkdPatchInfo::evalCachedBoxMean ( std::size_t rawId) const

Get the average point of the cached bounding box of the specified cell.

Parameters
rawIdis the raw id of the cell
Returns
The average point of the cached bounding box of the specified cell.

Definition at line 141 of file patch_skd_tree.cpp.

◆ evalCachedBoxMean() [2/2]

double bitpit::SkdPatchInfo::evalCachedBoxMean ( std::size_t rawId,
int direction ) const

Get the average point of the cached bounding box of the specified cell along the given direction.

Parameters
rawIdis the raw id of the cell
directionis the direction along which the mean is requested
Returns
The average point of the cached bounding box of the specified cell.

Definition at line 155 of file patch_skd_tree.cpp.

◆ getCachedBox()

const std::array< std::array< double, 3 >, 2 > & bitpit::SkdPatchInfo::getCachedBox ( std::size_t rawId) const

Get a the points that define the bounding box of the specified cell.

The first point defines the minimum point of the bounding box, whereas the second point defines the maximum point of the bounding box.

Parameters
rawIdis the raw id of the cell
Returns
The minimum point of the cached bounding box of the specified cell.

Definition at line 130 of file patch_skd_tree.cpp.

◆ getCellRawId()

std::size_t bitpit::SkdPatchInfo::getCellRawId ( std::size_t n) const

Get the n-th cell raw id.

Parameters
nis the requested raw id
Returns
The n-th cell raw id.

Definition at line 116 of file patch_skd_tree.cpp.

◆ getCellRawIds()

const std::vector< std::size_t > & bitpit::SkdPatchInfo::getCellRawIds ( ) const

Get a constant reference to the list of cell raw ids.

Returns
A constant reference to the list of cell raw ids.

Definition at line 105 of file patch_skd_tree.cpp.

◆ getPatch()

const PatchKernel & bitpit::SkdPatchInfo::getPatch ( ) const

Get a constant reference to the patch.

Returns
A constant reference to the patch.

Definition at line 95 of file patch_skd_tree.cpp.

Friends And Related Symbol Documentation

◆ PatchSkdTree

friend class PatchSkdTree
friend

Definition at line 38 of file patch_skd_tree.hpp.

Member Data Documentation

◆ m_cellBoxes

std::unique_ptr<BoxCache> bitpit::SkdPatchInfo::m_cellBoxes
protected

Definition at line 62 of file patch_skd_tree.hpp.

◆ m_cellRawIds

const std::vector<std::size_t>* bitpit::SkdPatchInfo::m_cellRawIds
protected

Definition at line 60 of file patch_skd_tree.hpp.

◆ m_patch

const PatchKernel* bitpit::SkdPatchInfo::m_patch
protected

Definition at line 59 of file patch_skd_tree.hpp.


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