Go to the documentation of this file.
47 faceZoneToCell::typeName,
48 "\n Usage: faceZoneToCell zone master|slave\n\n"
49 " Select master or slave side of the faceZone."
50 " Note:accepts wildcards for zone.\n\n"
58 Foam::faceZoneToCell::faceActionNames_
60 { faceAction::MASTER,
"master" },
61 { faceAction::SLAVE,
"slave" },
67 void Foam::faceZoneToCell::combine(topoSet& set,
const bool add)
const
69 bool hasMatched =
false;
73 if (selectedZones_.
match(zone.name()))
86 Info<<
" Found matching zone " << zone.name()
87 <<
" with " << cellLabels.size() <<
" cells on "
88 << faceActionNames_[option_] <<
" side" <<
endl;
91 for (
const label celli : cellLabels)
105 <<
"Cannot find any faceZone matching "
123 selectedZones_(
one(), zoneName),
136 option_(faceActionNames_.get(
"option",
dict))
141 selectedZones_.resize(1);
142 selectedZones_.first() =
155 selectedZones_(
one(),
wordRe(checkIs(is))),
156 option_(faceActionNames_.read(checkIs(is)))
172 Info<<
" Adding all " << faceActionNames_[option_]
173 <<
" cells of face zones "
183 Info<<
" Removing all " << faceActionNames_[option_]
184 <<
" cells of face zones "
addToRunTimeSelectionTable(decompositionMethod, kahipDecomp, dictionary)
List< label > labelList
A List of labels.
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
Class with constructor to add usage string to table.
A class representing the concept of 1 (one), which can be used to avoid manipulating objects that are...
Ostream & endl(Ostream &os)
Add newline and flush stream.
setAction
Enumeration defining the valid actions.
T getCompat(const word &keyword, std::initializer_list< std::pair< const char *, int >> compat, enum keyType::option=keyType::REGEX) const
Create a new set and ADD elements to it.
A wordRe is a Foam::word, but can contain a regular expression for matching words or strings.
Mesh consisting of general polyhedral cells.
const faceZoneMesh & faceZones() const
Return face zone mesh.
bool match(const std::string &text, bool literal=false) const
Smart match as literal or regex, stopping on the first match.
label nCells() const
Number of mesh cells.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
bool verbose_
Verbosity (default: true)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
messageStream Info
Information stream (uses stdout - output is on the master only)
AccessType combine(const UList< T > &lists, AccessOp aop=accessOp< T >())
Combines sub-lists into a single list.
General set of labels of mesh quantity (points, cells, faces).
faceAction
Enumeration defining the valid options.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
Macros for easy insertion into run-time selection tables.
Subtract elements from the set.
faceZoneToCell(const polyMesh &mesh, const wordRe &zoneName, const faceAction option)
Construct from components.
wordList names() const
A list of the zone names.
FlatOutput< Container > flatOutput(const Container &obj, label len=0)
Global flatOutput function.
Base class of a topoSet source for selecting cells.
void addOrDelete(topoSet &set, const label id, const bool add) const
Add or delete id from set. Add when 'add' is true.
const polyMesh & mesh_
Reference to the mesh.
defineTypeNameAndDebug(combustionModel, 0)
#define WarningInFunction
Report a warning using Foam::Warning.
virtual void applyToSet(const topoSetSource::setAction action, topoSet &set) const
Apply specified action to the topoSet.
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const