Flow123d
master-f44eb46
|
#include <region.hh>
Public Types | |
enum | RegionType { bulk =false , boundary =true } |
Public Member Functions | |
Region () | |
Default region is undefined/invalid. More... | |
Region (RegionIdx r_idx, const RegionDB &db) | |
RegionIdx | operator() (const Region &) |
std::string | label () const |
Returns label of the region (using RegionDB) More... | |
unsigned int | id () const |
Returns id of the region (using RegionDB) More... | |
unsigned int | dim () const |
Returns dimension of the region. More... | |
const RegionDB & | db () |
bool | is_in_region_set (const RegionSet &set) const |
Public Member Functions inherited from RegionIdx | |
RegionIdx () | |
Default region is undefined/invalid. More... | |
bool | is_boundary () const |
Returns true if it is a Boundary region and false if it is a Bulk region. More... | |
bool | is_valid () const |
Returns false if the region has undefined/invalid value. More... | |
unsigned int | idx () const |
Returns a global index of the region. More... | |
unsigned int | boundary_idx () const |
Returns index of the region in the boundary set. More... | |
unsigned int | bulk_idx () const |
Returns index of the region in the bulk set. More... | |
bool | operator== (const RegionIdx &other) const |
Equality comparison operators for regions. More... | |
bool | operator!= (const RegionIdx &other) const |
Equality comparison operators for regions. More... | |
Static Public Member Functions | |
static bool | comp (const Region &a, const Region &b) |
Comparative method of two regions. More... | |
Protected Member Functions | |
Region (unsigned int index, const RegionDB &db) | |
Protected Member Functions inherited from RegionIdx | |
RegionIdx (unsigned int index) | |
Protected Attributes | |
const RegionDB * | db_ |
Global variable with information about all regions. More... | |
Protected Attributes inherited from RegionIdx | |
unsigned int | idx_ |
Friends | |
class | RegionDB |
class | Mesh |
Additional Inherited Members | |
Static Protected Attributes inherited from RegionIdx | |
static const unsigned int | undefined =0xffffffff |
index for undefined region More... | |
Class that represents disjoint part of computational domain (or domains). It consists of one integer value but provides access to other data stored in RegionDB. In particular provides string label and integer ID (unordered) further it provides fast (inlined) methods to: 1) detect if the region is the bulk region or boundary region 2) return index (this is used to select correct Field, possibly we can distinguish boundary_index and bulk_index)
Implementation: currently we number bulk regions by odd indices and boundary regions by even indices.
enum Region::RegionType |
|
inline |
|
inlineprotected |
|
inline |
unsigned int Region::dim | ( | ) | const |
unsigned int Region::id | ( | ) | const |
bool Region::is_in_region_set | ( | const RegionSet & | set | ) | const |
std::string Region::label | ( | ) | const |
|
protected |