54 Foam::faceToCell::faceActionNames_;
59 void Foam::faceToCell::combine(topoSet& set,
const bool add)
const
62 faceSet loadedSet(
mesh_, setName_);
68 const label facei = iter.key();
70 if ((option_ ==
OWNER) || (option_ ==
ANY))
93 Map<label> facesPerCell(loadedSet.size());
97 const label facei = iter.key();
102 if (fndOwn == facesPerCell.end())
104 facesPerCell.insert(own, 1);
117 if (fndNei == facesPerCell.end())
119 facesPerCell.insert(nei, 1);
132 const label celli = iter.key();
165 setName_(
dict.lookup(
"set")),
166 option_(faceActionNames_.
read(
dict.lookup(
"option")))
186 Info<<
" Adding cells according to faceSet " << setName_
193 Info<<
" Removing cells according to faceSet " << setName_
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
Macros for easy insertion into run-time selection tables.
void size(const label)
Override size to be inconsistent with allocated storage.
HashTable< label, label, Hash< label > >::iterator iterator
Initialise the NamedEnum HashTable from the static list of names.
A list of keyword definitions, which are a keyword followed by any number of values (e....
A topoSetSource to select cells based on usage in faces.
virtual void applyToSet(const topoSetSource::setAction action, topoSet &) const
faceToCell(const polyMesh &mesh, const word &setName, const faceAction option)
Construct from components.
virtual ~faceToCell()
Destructor.
faceAction
Enumeration defining the valid options.
Mesh consisting of general polyhedral cells.
virtual const labelList & faceOwner() const
Return face owner.
virtual const labelList & faceNeighbour() const
Return face neighbour.
bool isInternalFace(const label faceIndex) const
Return true if given face label is internal to the mesh.
const cellList & cells() const
Base class of a source for a topoSet.
void addOrDelete(topoSet &set, const label celli, const bool) const
Add (if bool) celli to set or delete celli from set.
setAction
Enumeration defining the valid actions.
General set of labels of mesh quantity (points, cells, faces).
A class for handling words, derived from string.
bool read(const char *, int32_t &)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
defineTypeNameAndDebug(combustionModel, 0)
treeBoundBox combine(const treeBoundBox &a, const treeBoundBox &b)
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)