43 bool duplicates =
false;
45 for (
const word& w : list)
48 auto iter = hashed.
find(w);
63 Info<<
nl <<
"WARNING: " << context <<
" with identical names:";
68 Info<<
" " << iter.key();
78void Foam::meshReader::writeInterfaces(
const objectRegistry& registry)
const
95 ioObj.note() =
"as yet unsupported interfaces (baffles)";
97 Info<<
"Writing " << ioObj.name() <<
" to " << ioObj.objectPath() <<
endl;
100 ioObj.writeHeader(
os);
107void Foam::meshReader::writeMeshLabelList
109 const objectRegistry& registry,
110 const word& propertyName,
112 IOstreamOption streamOpt
116 IOListRef<label> ioObj
121 registry.time().constant(),
132 ioObj.note() =
"persistent data for STARCD <-> OPENFOAM translation";
133 Info<<
"Writing " << ioObj.name() <<
" to " << ioObj.objectPath() <<
endl;
139 ioObj.writeObject(streamOpt,
true);
147 cellTable_.writeDict(registry);
148 writeInterfaces(registry);
A HashTable similar to std::unordered_map.
bool insert(const Key &key, const T &obj)
Copy insert a new entry, not overwriting existing entries.
iterator find(const Key &key)
Find and return an iterator set at the hashed entry.
A List of objects of type <T> with automated input and output.
@ NO_REGISTER
Do not request registration (bool: false).
@ NO_READ
Nothing to be read.
@ NO_WRITE
Ignore writing from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
static Ostream & writeEndDivider(Ostream &os)
Write the standard end file divider.
A simple container for options an IOstream can normally have.
@ ASCII
"ascii" (normal default)
Output to file stream as an OSstream, normally using std::ofstream for the actual output.
const word & constant() const noexcept
Return constant name.
void size(const label n)
Older name for setAddressableSize.
static void warnDuplicates(const word &context, const wordList &)
Warn about repeated names.
void writeAux(const objectRegistry &) const
Write auxiliary information.
cellTable cellTable_
Cell table persistent data saved as a dictionary.
labelList cellTableId_
Cell table id for each cell.
labelList origCellId_
Lookup original Cell number for a given cell.
Registry of regIOobjects.
const Time & time() const noexcept
Return time registry.
static word meshSubDir
Return the mesh sub-directory name (usually "polyMesh").
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
List< word > wordList
List of word.
messageStream Info
Information stream (stdout output on master, null elsewhere).
Ostream & endl(Ostream &os)
Add newline and flush stream.
UList< label > labelUList
A UList of labels.
constexpr char nl
The newline '\n' character (0x0a).
#define forAllConstIters(container, iter)
Iterate across all elements of the container object with const access.