Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
volRegion Class Reference

Volume (cell) region selection class. More...

Inheritance diagram for volRegion:
Inheritance graph
[legend]
Collaboration diagram for volRegion:
Collaboration graph
[legend]

Public Types

enum  regionTypes { vrtCellZone, vrtAll }
 Region type enumeration. More...
 

Public Member Functions

 TypeName ("volRegion")
 Run-time type information. More...
 
 volRegion (const fvMesh &mesh, const dictionary &dict)
 Construct from fvMesh and dictionary. More...
 
virtual ~volRegion ()
 Destructor. More...
 
bool read (const dictionary &)
 Read from dictionary. More...
 
const regionTypesregionType () const
 Return the region type. More...
 
const labelListcellIDs () const
 Return the local list of cell IDs. More...
 
label nCells () const
 Return the number of cells in the region. More...
 
scalar V () const
 Return total volume of the region. More...
 

Static Public Attributes

static const NamedEnum< regionTypes, 2 > regionTypeNames_
 Region type names. More...
 

Protected Member Functions

void writeFileHeader (const writeFile &wf, Ostream &file)
 Output file header information. More...
 

Protected Attributes

regionTypes regionType_
 Region type. More...
 
word regionName_
 Region name (patch, zone, etc.) More...
 
label regionID_
 Region ID (patch ID, zone ID, etc.) More...
 

Detailed Description

Volume (cell) region selection class.

Examples of function object specification:

volRegion0
{
    .
    .
    regionType      cellZone;
    name            c0;
    .
    .
}

volRegionAll
{
    .
    .
    regionType      all;
    .
    .
}
Usage
Property Description Required Default value
regionType cellZone or all no all
name Name of cellZone if required no
See also
Foam::functionObject
Source files

Definition at line 102 of file volRegion.H.

Member Enumeration Documentation

◆ regionTypes

Region type enumeration.

Enumerator
vrtCellZone 
vrtAll 

Definition at line 118 of file volRegion.H.

Constructor & Destructor Documentation

◆ volRegion()

volRegion ( const fvMesh mesh,
const dictionary dict 
)

Construct from fvMesh and dictionary.

Definition at line 74 of file volRegion.C.

References Foam::read().

Referenced by volRegion::writeFileHeader().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ~volRegion()

~volRegion ( )
virtual

Destructor.

Definition at line 98 of file volRegion.C.

References volRegion::read().

Here is the call graph for this function:

Member Function Documentation

◆ writeFileHeader()

void writeFileHeader ( const writeFile wf,
Ostream file 
)
protected

Output file header information.

Definition at line 58 of file volRegion.C.

References Foam::endl(), Foam::setw(), volRegion::volRegion(), writeFile::writeCommented(), and writeFile::writeHeaderValue().

Referenced by NamedEnum< directionType, 3 >::names(), and volFieldValue::writeFileHeader().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TypeName()

TypeName ( "volRegion"  )

Run-time type information.

◆ read()

bool read ( const dictionary dict)

Read from dictionary.

Definition at line 105 of file volRegion.C.

References Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, dictionary::lookup(), and Foam::nl.

Referenced by volRegion::~volRegion().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ regionType()

const Foam::functionObjects::volRegion::regionTypes & regionType ( ) const
inline

Return the region type.

Definition at line 29 of file volRegionI.H.

References volRegion::regionType_.

◆ cellIDs()

const Foam::labelList & cellIDs ( ) const

Return the local list of cell IDs.

Definition at line 155 of file volRegion.C.

References List< label >::null().

Here is the call graph for this function:

◆ nCells()

Foam::label nCells ( ) const

Return the number of cells in the region.

Definition at line 168 of file volRegion.C.

References Foam::returnReduce().

Here is the call graph for this function:

◆ V()

Foam::scalar V ( ) const

Return total volume of the region.

Definition at line 181 of file volRegion.C.

References Foam::gSum().

Here is the call graph for this function:

Member Data Documentation

◆ regionTypeNames_

Region type names.

Definition at line 125 of file volRegion.H.

Referenced by NamedEnum< directionType, 3 >::names().

◆ regionType_

regionTypes regionType_
protected

Region type.

Definition at line 133 of file volRegion.H.

Referenced by volRegion::regionType().

◆ regionName_

word regionName_
protected

Region name (patch, zone, etc.)

Definition at line 136 of file volRegion.H.

◆ regionID_

label regionID_
protected

Region ID (patch ID, zone ID, etc.)

Definition at line 139 of file volRegion.H.


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