41#ifndef Foam_topoSetSource_H
42#define Foam_topoSetSource_H
291 const word sourceTypeName(is);
331 const word& topoSetSourceType,
339 const word& topoSetSourceType,
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
A HashTable similar to std::unordered_map.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
static autoPtr< Time > New()
Construct (dummy) Time - no functionObjects or libraries.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
A bitSet stores bits (elements with only two states) in packed internal format and supports a variety...
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Mesh consisting of general polyhedral cells.
Class with constructor to add usage string to table.
addToUsageTable(const word &name, const string &msg)
Class used for the read-construction of.
iNew(const polyMesh &mesh)
autoPtr< topoSetSource > operator()(Istream &is) const
Base class of a source for a topoSet.
static bool isZoneSource(const sourceType t) noexcept
True if a "zone" source.
virtual sourceType setType() const =0
The source category (cell/face/point combined with set/zone)
static bool isPoint(const sourceType t) noexcept
True if "point" geometric type.
static const string illegalSource_
sourceType
Enumeration defining the types of sources.
@ CELL_TYPE
Geometric type is "cell".
@ POINTSET_SOURCE
Points as set.
@ FACESET_SOURCE
Faces as set.
@ FACEZONE_SOURCE
Faces as zone.
@ UNKNOWN_SOURCE
Placeholder.
@ POINTZONE_SOURCE
Points as zone.
@ CELLSET_SOURCE
Cells as set.
@ CELLZONE_SOURCE
Cells as zone.
@ POINT_TYPE
Geometric type is "point".
@ ZONE_SOURCE
A source based on mesh zone.
@ FACE_TYPE
Geometric type is "face".
@ SET_SOURCE
A source based on topoSet.
void addOrDelete(topoSet &set, const label id, const bool add) const
Add or delete id from set. Add when 'add' is true.
static bool check(labelList &list, const label maxLabel)
Detect and remove any values less than 0 or ge maxLabel.
static setAction toAction(const word &actionName)
Deprecated(2018-07) convert string to action.
topoSetSource(const topoSetSource &)=delete
No copy construct.
static bool isCell(const sourceType t) noexcept
True if "cell" geometric type.
setAction
Enumeration defining various actions.
@ CLEAR
Clear the set, possibly creating it.
@ SUBSET
Union of elements with current set.
@ LIST
Print contents of the set.
@ REMOVE
Remove the set (from the file system)
@ IGNORE
"ignore" no-op action
@ SUBTRACT
Subtract elements from current set.
@ INVERT
Invert the elements in the current set.
@ ADD
Add elements to current set.
@ NEW
Create a new set and ADD elements to it.
static bool isFace(const sourceType t) noexcept
True if "face" geometric type.
void operator=(const topoSetSource &)=delete
No copy assignment.
virtual ~topoSetSource()=default
Destructor.
static HashTable< string > * usageTablePtr_
A table of usage strings.
static const string & usage(const word &name)
declareRunTimeSelectionTable(autoPtr, topoSetSource, word,(const polyMesh &mesh, const dictionary &dict),(mesh, dict))
declareRunTimeSelectionTable(autoPtr, topoSetSource, istream,(const polyMesh &mesh, Istream &is),(mesh, is))
bool verbose_
Output verbosity (default: true)
autoPtr< topoSetSource > clone() const
Clone (disallowed)
bool verbose() const noexcept
Get output verbosity.
const polyMesh & mesh() const noexcept
Reference to the mesh.
static autoPtr< topoSetSource > New(const word &topoSetSourceType, const polyMesh &mesh, const dictionary &dict)
Return a reference to the selected topoSetSource.
TypeName("topoSetSource")
Runtime type information.
const polyMesh & mesh_
Reference to the mesh.
static Istream & checkIs(Istream &is)
Check state of stream.
static const Enum< setAction > actionNames
virtual void applyToSet(const topoSetSource::setAction action, topoSet &set) const =0
Apply specified action to the topoSet.
static const Enum< setAction > combineNames
static bool isSetSource(const sourceType t) noexcept
True if a "set" source.
General set of labels of mesh quantity (points, cells, faces).
A class for handling words, derived from Foam::string.
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
Macros to ease declaration of run-time selection tables.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.