56 const std::string & region_type);
97 const std::vector<std::reference_wrapper<const CSGSurface>> &
getSurfaces()
const 122 std::vector<std::reference_wrapper<const CSGSurface>>
_surfaces;
std::string _region_str
String representation of region - defaults to empty string.
CSGRegions creates an internal representation of a CSG region, which can refer to an intersection...
CSGRegion()
Default Constructor.
const std::string & toString() const
gets the string representation of the region
Halfspace
Enum for the sign of the half-space being represented by a point and surface.
const CSGRegion operator|(const CSGRegion ®ion_a, const CSGRegion ®ion_b)
Overload for creating a region from the union (|) of two regions.
virtual ~CSGRegion()=default
Destructor.
T getEnum() const
get the current value cast to the enum type T
bool operator!=(const CSGRegion &other) const
Operator overload for checking if two CSGRegion objects are not equal.
const CSGRegion operator+(const CSGSurface &surf)
Operation overloads for operation based region construction.
CSGRegion & operator|=(const CSGRegion &other_region)
Operator overload for |= which creates a union of the current region with the other_region.
bool operator==(const CSGRegion &other) const
Operator overload for checking if two CSGRegion objects are equal.
const CSGRegion operator &(const CSGRegion ®ion_a, const CSGRegion ®ion_b)
Overload for creating a region from the the intersection (&) of two regions.
RegionType getRegionType() const
Get the region type.
CSGRegion & operator &=(const CSGRegion &other_region)
Operator overload for &= which creates an intersection between the current region and the other_regio...
const std::vector< std::reference_wrapper< const CSGSurface > > & getSurfaces() const
Get the list of surfaces associated with the region.
MooseEnum _region_type
An enum for type of type of operation that defines region.
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
RegionType
Enum for representing region types, defined to match _region_type MooseEnum.
CSGSurface creates an internal representation of a Constructive Solid Geometry (CSG) surface...
std::vector< std::reference_wrapper< const CSGSurface > > _surfaces
Surface list associated with the region.
const CSGRegion operator~(const CSGRegion ®ion)
Overload for creating a region from the complement (~) of another region.
const std::string stripRegionString(std::string region_str, std::string op)
strip the leading and trailing parentheses from the string if only the specified operator is present ...
const std::string getRegionTypeString() const
Get the region type as a string.
const CSGRegion operator-(const CSGSurface &surf)
Overload for creating a region from the negative half-space (-) of a surface.