IBAMR  IBAMR version 0.19.
Public Member Functions | Protected Attributes | List of all members
IBTK::PartitioningBoxes Class Reference

Class PartitioningBoxes stores a set of bounding boxes and can check if a point is in the set of partitioning boxes or not in a more optimized way than just looping over a std::vector<PartitioningBox>. More...

#include <ibtk/PartitioningBox.h>

Public Member Functions

 PartitioningBoxes ()=default
 
template<typename ForwardIterator >
 PartitioningBoxes (const ForwardIterator begin, const ForwardIterator end)
 Constructor. Creates an object from a sequence of partitioning boxes. More...
 
 PartitioningBoxes (const SAMRAI::hier::PatchHierarchy< NDIM > &hierarchy)
 
const Pointbottom () const
 
const Pointtop () const
 
bool contains (const Point &point) const
 
const PartitioningBoxbegin () const
 Return a pointer to the first partitioning box. More...
 
const PartitioningBoxend () const
 

Protected Attributes

PartitioningBox d_bounding_partitioning_box
 The partitioning box that bounds all other partitioning boxes. More...
 
std::vector< PartitioningBoxd_boxes
 The set of bounding boxes. More...
 

Detailed Description

It is possible for the set of bounding boxes to be empty: in that case the bounds are [oo, oo) in each dimension.

Constructor & Destructor Documentation

◆ PartitioningBoxes() [1/3]

IBTK::PartitioningBoxes::PartitioningBoxes ( )
default

Default constructor: an empty collection of partitioning boxes with bounds at oo.

◆ PartitioningBoxes() [2/3]

template<typename ForwardIterator >
IBTK::PartitioningBoxes::PartitioningBoxes ( const ForwardIterator  begin,
const ForwardIterator  end 
)
inline

◆ PartitioningBoxes() [3/3]

IBTK::PartitioningBoxes::PartitioningBoxes ( const SAMRAI::hier::PatchHierarchy< NDIM > &  hierarchy)

Constructor. Uses the finest level boxes on the provided PatchHierarchy to create a set of bounding boxes.

Member Function Documentation

◆ bottom()

const Point & IBTK::PartitioningBoxes::bottom ( ) const
inline

Get the bottom left corner of the partitioning box bounding all other partitioning boxes.

◆ top()

const Point & IBTK::PartitioningBoxes::top ( ) const
inline

Get the top right corner of the partitioning box bounding all other partitioning boxes. Note that this point is not in the collection of boxes.

◆ contains()

bool IBTK::PartitioningBoxes::contains ( const Point point) const
inline

Return true if the point is inside the set of boxes and false otherwise.

◆ begin()

const PartitioningBox * IBTK::PartitioningBoxes::begin ( ) const
inline

◆ end()

const PartitioningBox * IBTK::PartitioningBoxes::end ( ) const
inline

Return a pointer to one past the end of the end of the partitioning box array.

Member Data Documentation

◆ d_bounding_partitioning_box

PartitioningBox IBTK::PartitioningBoxes::d_bounding_partitioning_box
protected

◆ d_boxes

std::vector<PartitioningBox> IBTK::PartitioningBoxes::d_boxes
protected

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