51 label padding = (12 - label(key.size()));
58 while (--padding > 0);
68void Foam::decomposedBlockData::writeHeaderContent
71 IOstreamOption streamOptContainer,
72 const word& objectType,
74 const fileName& location,
75 const word& objectName
88 if (objectType.empty())
98 if (!location.empty())
143 const word& objectType,
146 const word& objectName,
157 decomposedBlockData::writeHeaderContent
167 if (!extraEntries.empty())
193 if (metaDataDict && !metaDataDict->empty())
195 dict.
add(
"meta", *metaDataDict);
214 decomposedBlockData::writeHeaderContent
231 if (metaDataDict && !metaDataDict->empty())
Input/output streams with managed List storage.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const word & name() const noexcept
Return the object name.
const word & headerClassName() const noexcept
Return name of the class name read from header.
bool readHeader(Istream &is)
static bool bannerEnabled() noexcept
Status of output file banner.
static Ostream & writeDivider(Ostream &os)
Write the standard file section divider.
virtual const dictionary * findMetaData() const noexcept
Return pointer to meta-data (if any) or nullptr.
static Ostream & writeBanner(Ostream &os, const bool noSyntaxHint=false)
Write the standard OpenFOAM file/dictionary banner.
const objectRegistry & db() const noexcept
Return the local objectRegistry.
const fileName & local() const noexcept
Read access to local path component.
const fileName & instance() const noexcept
Read access to instance path component.
const string & note() const noexcept
Return the optional note.
The IOstreamOption is a simple container for options an IOstream can normally have.
versionNumber version() const noexcept
Get the stream version.
streamFormat format() const noexcept
Get the current stream format.
virtual const fileName & name() const
Return the name of the stream.
virtual const fileName & name() const
Return the name of the stream.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
virtual Ostream & write(const char c)
Write character.
virtual void indent()
Add indentation characters.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
virtual Ostream & endBlock()
Write end block group.
virtual Ostream & beginBlock(const keyType &kw)
Write begin block group with the given name.
Similar to IStringStream but using an externally managed buffer for its input. This allows the input ...
static bool readBlockEntry(Istream &is, List< char > &charData)
Helper: read block of (binary) character data.
static void writeHeader(Ostream &os, IOstreamOption streamOptContainer, const word &objectType, const string ¬e, const fileName &location, const word &objectName, const dictionary &extraEntries)
Helper: write FoamFile IOobject header.
static void writeExtraHeaderContent(dictionary &dict, IOstreamOption streamOptData, const IOobject &io)
Helper: generate additional entries for FoamFile header.
static bool isCollatedType(const word &objectType)
True if object type is a known collated type.
static bool readHeader(IOobject &io, Istream &is)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const
void writeEntries(Ostream &os, const bool extraNewLine=false) const
Write dictionary entries.
void writeEntry(Ostream &os) const
Write sub-dictionary with its dictName as its header.
entry * add(entry *entryPtr, bool mergeEntry=false)
Add a new entry.
entry * set(entry *entryPtr)
Assign a new entry, overwriting any existing entry.
A class for handling file names.
virtual const fileName & dbDir() const
Local directory path of this objectRegistry relative to the time.
@ END_STATEMENT
End entry [isseparator].
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
IOobject io("surfaceFilmProperties", mesh.time().constant(), mesh, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE, false)
const std::string buildArch
static void writeHeaderEntry(Ostream &os, const word &key, const T &value)
constexpr char nl
The newline '\n' character (0x0a)
static const char *const typeName
The type name used in ensight case files.