60 patchToPoint::typeName,
61 "\n Usage: patchToPoint patch\n\n"
62 " Select all points in the pointPatch."
63 " Note:accepts wildcards for patch.\n\n"
69void Foam::patchToPoint::combine(topoSet& set,
const bool add)
const
72 const pointBoundaryMesh&
pbm = pMesh.boundary();
76 pbm.indices(selectedPatches_,
true)
81 const pointPatch&
pp =
pbm[patchi];
85 Info<<
" Found matching patch " <<
pp.name() <<
" with "
89 for (
const label pointi :
pp.meshPoints())
98 <<
"Cannot find any patches matching "
110 const polyMesh&
mesh,
111 const wordRe& patchName
115 selectedPatches_(
one{}, patchName)
129 if (!
dict.readIfPresent(
"patches", selectedPatches_))
131 selectedPatches_.resize(1);
132 selectedPatches_.front() =
133 dict.getCompat<wordRe>(
"patch", {{
"name", 1806}});
140 const polyMesh&
mesh,
161 Info<<
" Adding all points of patches: "
171 Info<<
" Removing all points of patches: "
Macros for easy insertion into run-time selection tables.
#define addNamedToRunTimeSelectionTable(baseType, thisType, argNames, lookupName)
Add to construction table with 'lookupName' as the key.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
uindirectPrimitivePatch pp(UIndirectList< face >(mesh.faces(), faceLabels), mesh.points())
const polyBoundaryMesh & pbm
@ READ_IF_PRESENT
Reading is optional [identical to LAZY_READ].
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
static FOAM_NO_DANGLING_REFERENCE const pointMesh & New(const polyMesh &mesh, Args &&... args)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A class representing the concept of 1 (one) that can be used to avoid manipulating objects known to b...
A topoSetPointSource to select points associated with given patch(es).
virtual void applyToSet(const topoSetSource::setAction action, topoSet &set) const
Apply specified action to the topoSet.
patchToPoint(const polyMesh &mesh, const wordRe &patchName)
Construct from components.
Mesh consisting of general polyhedral cells.
The topoSetPointSource is a intermediate class for handling topoSet sources for selecting points.
topoSetPointSource(const polyMesh &mesh)
Construct from mesh.
Class with constructor to add usage string to table.
Base class of a source for a topoSet.
void addOrDelete(topoSet &set, const label id, const bool add) const
Add or delete id from set. Add when 'add' is true.
setAction
Enumeration defining various actions.
@ SUBTRACT
Subtract elements from current set.
@ ADD
Add elements to current set.
@ NEW
Create a new set and ADD elements to it.
bool verbose_
Output verbosity (default: true).
const polyMesh & mesh() const noexcept
Reference to the mesh.
const polyMesh & mesh_
Reference to the mesh.
static Istream & checkIs(Istream &is)
Check state of stream.
General set of labels of mesh quantity (points, cells, faces).
A wordRe is a Foam::word, but can contain a regular expression for matching words or strings.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
#define WarningInFunction
Report a warning using Foam::Warning.
List< label > labelList
A List of labels.
messageStream Info
Information stream (stdout output on master, null elsewhere).
T returnReduce(const T &value, BinaryOp bop, const int tag=UPstream::msgType(), const int communicator=UPstream::worldComm)
Perform reduction on a copy, using specified binary operation.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void add(DimensionedField< scalar, GeoMesh > &result, const dimensioned< scalar > &dt1, const DimensionedField< scalar, GeoMesh > &f2)
FlatOutput::OutputAdaptor< Container, Delimiters > flatOutput(const Container &obj, Delimiters delim)
Global flatOutput() function with specified output delimiters.
constexpr char nl
The newline '\n' character (0x0a).
dict add("bounds", meshBb)