Go to the documentation of this file.
39 #ifndef polyBoundaryMesh_H
40 #define polyBoundaryMesh_H
57 Ostream&
operator<<(Ostream&
os,
const polyBoundaryMesh& pbm);
90 bool hasGroupIDs()
const;
93 void calcGroupIDs()
const;
215 const bool useGroups =
true
224 const bool useGroups =
true
235 const word& patchName,
236 const bool allowNotFound =
true
244 label
whichPatch(
const label faceIndex)
const;
261 const bool warnNotFound =
true,
262 const bool useGroups =
true
309 using polyPatchList::operator[];
329 return this->
indices(key, useGroups);
labelList patchSizes() const
Return a list of patch sizes.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
label nFaces() const
The number of boundary faces in the underlying mesh.
void matchGroups(const labelUList &patchIDs, wordList &groups, labelHashSet &nonGroupPatches) const
Match the patches to groups.
A class for handling words, derived from Foam::string.
wordList physicalTypes() const
Return a list of physical types.
A polyBoundaryMesh is a polyPatch list with additional search methods and registered IO.
const HashTable< labelList > & groupPatchIDs() const
The patch indices per patch group.
void reorder(const labelUList &oldToNew, const bool validBoundary)
Reorders patches. Ordering does not have to be done in.
auto key(const Type &t) -> typename std::enable_if< std::is_enum< Type >::value, typename std::underlying_type< Type >::type >::type
void clearGeom()
Clear geometry at this level and at patches.
void clearAddressing()
Clear addressing at this level and at patches.
A wordRe is a Foam::word, but can contain a regular expression for matching words or strings.
label start() const
The start label of the boundary faces in the polyMesh face list.
label findIndex(const wordRe &key) const
Return patch index for the first match, return -1 if not found.
wordList types() const
Return a list of patch types.
Mesh consisting of general polyhedral cells.
wordList names() const
Return a list of patch names.
labelRange range() const
The face range for all boundary faces.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
const labelList & patchID() const
Per boundary face label the patch index.
bool checkParallelSync(const bool report=false) const
Check whether all procs have all patches and in same order. Return.
const polyMesh & mesh() const noexcept
Return the mesh reference.
A patch is a list of labels that address the faces in the global face list.
UPtrList< const labelUList > faceCells() const
Return a list of faceCells for each patch.
bool checkDefinition(const bool report=false) const
Check boundary definition. Return true if in error.
labelHashSet findPatchIDs() const
Find patch indices for a given polyPatch type.
TypeName("polyBoundaryMesh")
Runtime type information.
The IOstreamOption is a simple container for options an IOstream can normally have.
labelList patchStarts() const
Return a list of patch start face indices.
A list of pointers to objects of type <T>, without allocation/deallocation management of the pointers...
A range or interval of labels defined by a start and a size.
label whichPatch(const label faceIndex) const
Return patch index for a given face label.
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
wordList patchNames(nPatches)
label findPatchID(const word &patchName, const bool allowNotFound=true) const
Find patch index given a name, return -1 if not found.
OBJstream os(runTime.globalPath()/outputName)
void movePoints(const pointField &p)
Correct polyBoundaryMesh after moving points.
A HashTable similar to std::unordered_map.
void updateMesh()
Correct polyBoundaryMesh after topology update.
label nNonProcessor() const
The number of patches before the first processor patch.
virtual bool writeData(Ostream &os) const
writeData member function required by regIOobject
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
const List< labelPairList > & neighbourEdges() const
Per patch the edges on the neighbouring patch.
virtual bool writeObject(IOstreamOption streamOpt, const bool valid) const
Write using stream options.
friend Ostream & operator<<(Ostream &os, const polyBoundaryMesh &pbm)
labelList indices(const wordRe &matcher, const bool useGroups=true) const
Return (sorted) patch indices for all matches.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
void setGroup(const word &groupName, const labelUList &patchIDs)
Set/add group with patches.
A List of wordRe with additional matching capabilities.
labelHashSet patchSet(const UList< wordRe > &patchNames, const bool warnNotFound=true, const bool useGroups=true) const
Return the set of patch IDs corresponding to the given names.
List< labelRange > patchRanges() const
Return a list of patch ranges.
class FOAM_DEPRECATED_FOR(2017-05, "Foam::Enum") NamedEnum
labelList findIndices(const wordRe &key, bool useGroups=true) const
Identical to the indices() method (AUG-2018)
static word groupName(StringType base, const word &group)
Create dot-delimited name.group string.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
const polyPatch & operator[](const word &patchName) const
Return const reference to polyPatch by name.
~polyBoundaryMesh()=default
Destructor.