Base class of a source for a topoSet
.
More...
Classes | |
class | addToUsageTable |
class | iNew |
Public Types | |
enum | sourceType { UNKNOWN_SOURCE = 0, CELL_TYPE = 0x1, FACE_TYPE = 0x2, POINT_TYPE = 0x4, SET_SOURCE = 0x10, CELLSET_SOURCE = (CELL_TYPE | SET_SOURCE), FACESET_SOURCE = (FACE_TYPE | SET_SOURCE), POINTSET_SOURCE = (POINT_TYPE | SET_SOURCE), ZONE_SOURCE = 0x20, CELLZONE_SOURCE = (CELL_TYPE | ZONE_SOURCE), FACEZONE_SOURCE = (FACE_TYPE | ZONE_SOURCE), POINTZONE_SOURCE = (POINT_TYPE | ZONE_SOURCE), CELLSETSOURCE = CELLSET_SOURCE, FACESETSOURCE = FACESET_SOURCE, POINTSETSOURCE = POINTSET_SOURCE, CELLZONESOURCE = CELLZONE_SOURCE, FACEZONESOURCE = FACEZONE_SOURCE, POINTZONESOURCE = POINTZONE_SOURCE } |
enum | setAction { ADD, NEW, SUBTRACT, SUBSET, INVERT, CLEAR, REMOVE, LIST, DELETE = SUBTRACT } |
Public Member Functions | |
TypeName ("topoSetSource") | |
declareRunTimeSelectionTable (autoPtr, topoSetSource, word,(const polyMesh &mesh, const dictionary &dict),(mesh, dict)) | |
declareRunTimeSelectionTable (autoPtr, topoSetSource, istream,(const polyMesh &mesh, Istream &is),(mesh, is)) | |
topoSetSource (const polyMesh &mesh, bool verbose=true) | |
topoSetSource (const polyMesh &mesh, const dictionary &dict) | |
autoPtr< topoSetSource > | clone () const |
virtual | ~topoSetSource ()=default |
const polyMesh & | mesh () const noexcept |
bool | verbose () const noexcept |
bool | verbose (bool on) noexcept |
void | verbose (const dictionary &dict) |
virtual sourceType | setType () const =0 |
virtual void | applyToSet (const topoSetSource::setAction action, topoSet &set) const =0 |
Static Public Member Functions | |
static Istream & | checkIs (Istream &is) |
static bool | isSetSource (const sourceType t) noexcept |
static bool | isZoneSource (const sourceType t) noexcept |
static bool | isCell (const sourceType t) noexcept |
static bool | isFace (const sourceType t) noexcept |
static bool | isPoint (const sourceType t) noexcept |
static const string & | usage (const word &name) |
static autoPtr< topoSetSource > | New (const word &topoSetSourceType, const polyMesh &mesh, const dictionary &dict) |
static autoPtr< topoSetSource > | New (const word &topoSetSourceType, const polyMesh &mesh, Istream &is) |
static setAction | toAction (const word &actionName) |
Static Public Attributes | |
static const Enum< setAction > | actionNames |
Protected Member Functions | |
void | addOrDelete (topoSet &set, const label id, const bool add) const |
void | addOrDelete (topoSet &set, const labelUList &labels, const bool add) const |
void | addOrDelete (topoSet &set, const bitSet &labels, const bool add) const |
topoSetSource (const topoSetSource &)=delete | |
void | operator= (const topoSetSource &)=delete |
Static Protected Member Functions | |
static bool | check (labelList &list, const label maxLabel) |
Protected Attributes | |
const polyMesh & | mesh_ |
bool | verbose_ |
Static Protected Attributes | |
static const string | illegalSource_ |
static HashTable< string > * | usageTablePtr_ = nullptr |
Base class of a source for a topoSet
.
Implementer must modify the given set (see applyToSet
) according to its function and the setAction
(one of add/delete/new).
Definition at line 63 of file topoSetSource.H.
enum sourceType |
Enumerator | |
---|---|
UNKNOWN_SOURCE | Placeholder. |
CELL_TYPE | Geometric type is "cell". |
FACE_TYPE | Geometric type is "face". |
POINT_TYPE | Geometric type is "point". |
SET_SOURCE | A source based on topoSet. |
CELLSET_SOURCE | Cells as set. |
FACESET_SOURCE | Faces as set. |
POINTSET_SOURCE | Points as set. |
ZONE_SOURCE | A source based on mesh zone. |
CELLZONE_SOURCE | Cells as zone. |
FACEZONE_SOURCE | Faces as zone. |
POINTZONE_SOURCE | Points as zone. |
CELLSETSOURCE | |
FACESETSOURCE | |
POINTSETSOURCE | |
CELLZONESOURCE | |
FACEZONESOURCE | |
POINTZONESOURCE |
Definition at line 70 of file topoSetSource.H.
enum setAction |
Enumerator | |
---|---|
ADD | Add elements to current set. |
NEW | Create a new set and ADD elements to it. |
SUBTRACT | Subtract elements from current set. |
SUBSET | Union of elements with current set. |
INVERT | Invert the elements in the current set. |
CLEAR | Clear the set, possibly creating it. |
REMOVE | Remove the set (from the file system) |
LIST | Print contents of the set. |
DELETE |
|
Definition at line 96 of file topoSetSource.H.
|
protecteddelete |
|
explicit |
Definition at line 226 of file topoSetSource.C.
topoSetSource | ( | const polyMesh & | mesh, |
const dictionary & | dict | ||
) |
Definition at line 237 of file topoSetSource.C.
References dict.
|
virtualdefault |
Definition at line 67 of file topoSetSource.C.
References List::resize().
Definition at line 164 of file topoSetSource.C.
References Foam::add(), and Foam::BitOps::set().
|
protected |
Definition at line 182 of file topoSetSource.C.
References Foam::add(), and Foam::BitOps::set().
Definition at line 200 of file topoSetSource.C.
References Foam::add(), and Foam::BitOps::set().
|
protecteddelete |
TypeName | ( | "topoSetSource" | ) |
|
static |
Definition at line 149 of file topoSetSource.C.
References IOstream::eof(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, and IOstream::good().
|
inlinestaticnoexcept |
Definition at line 203 of file topoSetSource.H.
References topoSetSource::SET_SOURCE.
|
inlinestaticnoexcept |
Definition at line 209 of file topoSetSource.H.
References topoSetSource::ZONE_SOURCE.
|
inlinestaticnoexcept |
Definition at line 215 of file topoSetSource.H.
References topoSetSource::CELL_TYPE.
|
inlinestaticnoexcept |
Definition at line 221 of file topoSetSource.H.
References topoSetSource::FACE_TYPE.
|
inlinestaticnoexcept |
Definition at line 227 of file topoSetSource.H.
References topoSetSource::POINT_TYPE.
declareRunTimeSelectionTable | ( | autoPtr | , |
topoSetSource | , | ||
word | , | ||
(const polyMesh &mesh, const dictionary &dict) | , | ||
(mesh, dict) | |||
) |
declareRunTimeSelectionTable | ( | autoPtr | , |
topoSetSource | , | ||
istream | , | ||
(const polyMesh &mesh, Istream &is) | , | ||
(mesh, is) | |||
) |
Definition at line 284 of file topoSetSource.H.
References topoSetSource::illegalSource_, Foam::name(), and topoSetSource::usageTablePtr_.
|
inline |
Definition at line 305 of file topoSetSource.H.
References NotImplemented.
|
static |
Definition at line 103 of file topoSetSource.C.
References dict, Foam::exit(), Foam::FatalIOError, FatalIOErrorInLookup, and mesh.
Referenced by topoSetSource::iNew::operator()().
|
static |
Definition at line 127 of file topoSetSource.C.
References Foam::exit(), Foam::FatalError, FatalErrorInLookup, and mesh.
|
inlinenoexcept |
Definition at line 338 of file topoSetSource.H.
References topoSetSource::mesh_.
|
inlinenoexcept |
Definition at line 344 of file topoSetSource.H.
References topoSetSource::verbose_.
Definition at line 351 of file topoSetSource.H.
References topoSetSource::verbose_.
void verbose | ( | const dictionary & | dict | ) |
Definition at line 250 of file topoSetSource.C.
References dict, and dictionary::readIfPresent().
|
pure virtual |
Implemented in topoSetCellZoneSource, topoSetFaceZoneSource, topoSetPointZoneSource, topoSetCellSource, topoSetFaceSource, and topoSetPointSource.
|
pure virtual |
Implemented in faceZoneToCell, surfaceToPoint, regionToCell, faceToCell, pointToFace, pointToCell, zoneToFace, zoneToCell, faceToPoint, zoneToPoint, cellToPoint, cylinderAnnulusToCell, rotatedBoxToCell, cylinderToCell, targetVolumeToCell, cylinderToFace, cylinderToPoint, fieldToCell, setsToFaceZone, searchableSurfaceToFaceZone, boxToCell, searchableSurfaceToCell, boxToFace, searchableSurfaceToFace, boxToPoint, searchableSurfaceToPoint, sphereToCell, sphereToFace, sphereToPoint, shapeToCell, normalToFace, patchToFace, haloToCell, cellToCell, patchToCell, faceToFace, pointToPoint, setToFaceZone, setAndNormalToFaceZone, setToPointZone, nearestToCell, nearestToPoint, setToCellZone, labelToCell, labelToFace, faceZoneToFaceZone, labelToPoint, nbrToCell, boundaryToCell, boundaryToFace, regionsToCell, badQualityToFace, badQualityToCell, surfaceToCell, planeToFaceZone, cylinderAnnulusToFace, and regionToFace.
Definition at line 379 of file topoSetSource.H.
References topoSetSource::actionNames.
|
static |
Definition at line 114 of file topoSetSource.H.
Referenced by topoSetSource::toAction().
|
staticprotected |
Definition at line 119 of file topoSetSource.H.
Referenced by topoSetSource::usage().
|
staticprotected |
Definition at line 122 of file topoSetSource.H.
Referenced by topoSetSource::addToUsageTable::addToUsageTable(), topoSetSource::usage(), and topoSetSource::addToUsageTable::~addToUsageTable().
|
protected |
Definition at line 152 of file topoSetSource.H.
Referenced by topoSetSource::mesh().
|
protected |
Definition at line 155 of file topoSetSource.H.
Referenced by topoSetSource::verbose().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.