51 Foam::faceZoneToCell::faceActionNames_;
56 void Foam::faceZoneToCell::combine(
topoSet&
set,
const bool add)
const 58 bool hasMatched =
false;
60 forAll(mesh_.faceZones(), i)
64 if (zoneName_.match(zone.
name()))
73 Info<<
" Found matching zone " << zone.
name()
75 <<
" cells on selected side." <<
endl;
82 if (cellLabels[i] >= 0 && cellLabels[i] < mesh_.nCells())
84 addOrDelete(
set, cellLabels[i], add);
93 <<
"Cannot find any faceZone named " << zoneName_ <<
endl 94 <<
"Valid names are " << mesh_.faceZones().names() <<
endl;
104 const word& zoneName,
122 option_(faceActionNames_.read(dict.
lookup(
"option")))
142 Info<<
" Adding all " << faceActionNames_[option_]
143 <<
" cells of faceZone " << zoneName_ <<
" ..." <<
endl;
149 Info<<
" Removing all " << faceActionNames_[option_]
150 <<
" cells of faceZone " << zoneName_ <<
" ..." <<
endl;
virtual void applyToSet(const topoSetSource::setAction action, topoSet &) const
#define forAll(list, i)
Loop across all elements in list.
A list of keyword definitions, which are a keyword followed by any number of values (e...
void size(const label)
Override size to be inconsistent with allocated storage.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const labelList & masterCells() const
Return labels of master cells (cells next to the master face.
Initialise the NamedEnum HashTable from the static list of names.
virtual ~faceZoneToCell()
Destructor.
Macros for easy insertion into run-time selection tables.
Base class of a source for a topoSet.
faceAction
Enumeration defining the valid options.
A class for handling words, derived from string.
setAction
Enumeration defining the valid actions.
const word & name() const
Return name.
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
defineTypeNameAndDebug(combustionModel, 0)
const labelList & slaveCells() const
Return labels of slave cells.
General set of labels of mesh quantity (points, cells, faces).
faceZoneToCell(const polyMesh &mesh, const word &zoneName, const faceAction option)
Construct from components.
#define WarningInFunction
Report a warning using Foam::Warning.
T returnReduce(const T &Value, const BinaryOp &bop, const int tag=Pstream::msgType(), const label comm=UPstream::worldComm)
Mesh consisting of general polyhedral cells.
A subset of mesh faces organised as a primitive patch.
ITstream & lookupBackwardsCompatible(const wordList &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream, trying a list of keywords.
treeBoundBox combine(const treeBoundBox &a, const treeBoundBox &b)
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.