49#ifndef UnsortedMeshedSurface_H
50#define UnsortedMeshedSurface_H
70template<
class Face>
class MeshedSurface;
71template<
class Face>
class MeshedSurfaceProxy;
72template<
class Face>
class UnsortedMeshedSurface;
117 void resize(
const label,
const Face&) =
delete;
120 void setSize(
const label,
const Face&) =
delete;
246 const bool isGlobal =
true
273 const word& fileType,
274 bool mandatory =
true
299 (
name, surf, streamOpt, options)
316 const word& fileType,
369 virtual void clear();
376 template<
class BoolListType>
379 const BoolListType& include,
466 const word& fileType,
471 write(
name, fileType, *
this, streamOpt, options);
498 friend Istream&
operator>> <Face>
506 friend Ostream& operator<< <Face>
Defines the attributes of an object for which implicit objectRegistry management is supported,...
The IOstreamOption is a simple container for options an IOstream can normally have.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
A proxy for writing MeshedSurface, UnsortedMeshedSurface and surfMesh to various file formats.
A surface geometry mesh with zone information, not to be confused with the similarly named surfaceMes...
label size() const
The surface size is the number of faces.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A surface geometry mesh, in which the surface zone information is conveyed by the 'zoneId' associated...
Face face_type
The face type (same as the underlying PrimitivePatch)
virtual void write(const fileName &name, IOstreamOption streamOpt=IOstreamOption(), const dictionary &options=dictionary::null) const
Write to file, choosing writer based on the file extension.
declareRunTimeSelectionTable(autoPtr, UnsortedMeshedSurface, fileExtension,(const fileName &name),(name))
static bool canWriteType(const word &fileType, bool verbose=false)
Can we write this file format? Also checks friend types.
autoPtr< labelList > releaseZoneIds()
Release (clear) stored zoneIds and return for reuse.
surfZoneList sortedZones(labelList &faceMap) const
Sort faces according to zoneIds.
static wordHashSet writeTypes()
Known writable file-types, without friends or proxies.
virtual void remapFaces(const labelUList &faceMapNewToOld)
Set new zones from faceMap.
void setZones(const surfZoneList &zoneLst)
Set zone ids and zones.
static bool canReadType(const word &fileType, bool verbose=false)
Can we read this file format? Also checks friend types.
void transfer(UnsortedMeshedSurface< Face > &surf)
Transfer the contents of the argument and annul the argument.
bool read(const fileName &name, const word &fileType)
Read from file with given format type.
virtual const labelList & zoneIds() const
Return const access to the zone ids.
labelList & storedZoneIds()
Return non-const access to the zone Ids.
static bool canRead(const fileName &name, bool verbose=false)
Can we read this file format?
label size() const
The surface size is the number of faces.
virtual ~UnsortedMeshedSurface()=default
Destructor.
List< surfZoneIdentifier > & storedZoneToc()
Return non-const access to the zone table-of-contents.
void operator=(const UnsortedMeshedSurface< Face > &surf)
Copy assignment.
TypeName("UnsortedMeshedSurface")
Declare type-name, virtual type (with debug switch)
void subsetMeshMap(const BoolListType &include, labelList &pointMap, labelList &faceMap) const
Create mappings for a sub-surface.
declareMemberFunctionSelectionTable(void, UnsortedMeshedSurface, write, fileExtension,(const fileName &name, const UnsortedMeshedSurface< Face > &surf, IOstreamOption streamOpt, const dictionary &options),(name, surf, streamOpt, options))
void setOneZone()
Set zones to 0 and set a single zone.
virtual void clear()
Clear all storage.
point point_type
The point type (same as the underlying PrimitivePatch)
friend class UnsortedMeshedSurface
static autoPtr< UnsortedMeshedSurface > New(const fileName &name, const word &fileType, bool mandatory=true)
Read construct from filename with given file type.
const List< surfZoneIdentifier > & zoneToc() const
Return const access to the zone table-of-contents.
void swap(MeshedSurface< Face > &surf)=delete
Swap contents - disabled.
UnsortedMeshedSurface subsetMesh(const UList< bool > &include, labelList &pointMap, labelList &faceMap) const
Return a new surface subsetted on the selected faces.
static wordHashSet readTypes()
Known readable file-types, without friends or proxies.
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,...
A class for handling file names.
A surface mesh consisting of general polygon faces that has IO capabilities and a registry for storin...
A class for handling words, derived from Foam::string.
static const word null
An empty word.
patchWriters resize(patchIds.size())
OBJstream os(runTime.globalPath()/outputName)
IOobject io("surfaceFilmProperties", mesh.time().constant(), mesh, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE, false)
Macros to ease declaration of member function selection tables.
#define declareMemberFunctionSelectionTable(returnType, baseType, funcName, argNames, argList, parListUnused)
Declare a run-time member-function selection (variables and adder classes)
Pair< int > faceMap(const label facePi, const face &faceP, const label faceNi, const face &faceN)
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
Istream & operator>>(Istream &, directionInfo &)
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
points setSize(newPointi)
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.