Go to the documentation of this file.
65 void Foam::decomposedBlockData::writeHeaderContent
68 IOstreamOption streamOptContainer,
69 const word& objectType,
71 const fileName& location,
72 const word& objectName
85 if (objectType.empty())
95 if (!location.empty())
140 const word& objectType,
143 const word& objectName,
154 decomposedBlockData::writeHeaderContent
164 if (!extraEntries.empty())
186 dict.
set(
"data.class", io.type());
190 if (metaDataDict && !metaDataDict->empty())
192 dict.
add(
"meta", *metaDataDict);
211 decomposedBlockData::writeHeaderContent
215 decomposedBlockData::typeName,
228 if (metaDataDict && !metaDataDict->empty())
Similar to IStringStream but using an externally managed buffer for its input. This allows the input ...
Defines the attributes of an object for which implicit objectRegistry management is supported,...
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.
A class for handling words, derived from Foam::string.
A class for handling file names.
const fileName & instance() const noexcept
static bool bannerEnabled() noexcept
Status of output file banner.
auto key(const Type &t) -> typename std::enable_if< std::is_enum< Type >::value, typename std::underlying_type< Type >::type >::type
streamFormat format() const noexcept
Get the current stream format.
void writeHeaderEntry(Ostream &os, const word &key, const T &value)
const word & headerClassName() const noexcept
Return name of the class name read from header.
virtual Ostream & beginBlock(const keyType &kw)
Write begin block group with the given name.
entry * set(entry *entryPtr)
Assign a new entry, overwriting any existing entry.
virtual Ostream & write(const char c)
Write character.
static Ostream & writeBanner(Ostream &os, const bool noSyntaxHint=false)
Write the standard OpenFOAM file/dictionary banner.
Input/output streams with managed List storage.
bool readHeader(Istream &is)
static void writeExtraHeaderContent(dictionary &dict, IOstreamOption streamOptData, const IOobject &io)
Helper: generate additional entries for FoamFile header.
virtual const fileName & dbDir() const
Local directory path of this objectRegistry relative to the time.
void writeEntry(Ostream &os) const
Write sub-dictionary with its dictName as its header.
void writeSpaces(Ostream &os, label nSpaces)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
const fileName & local() const noexcept
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
The IOstreamOption is a simple container for options an IOstream can normally have.
virtual const fileName & name() const
Return the name of the stream.
virtual const fileName & name() const
Return the name of the stream.
void writeEntries(Ostream &os, const bool extraNewLine=false) const
Write dictionary entries.
virtual Ostream & endBlock()
Write end block group.
static bool readBlockEntry(Istream &is, List< char > &charData)
Helper: read block of (binary) character data.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
static bool isCollatedType(const word &objectType)
True if object type is a known collated type.
OBJstream os(runTime.globalPath()/outputName)
Ostream & indent(Ostream &os)
Indent stream.
virtual const dictionary * findMetaData() const noexcept
Return pointer to meta-data (if any) or nullptr.
const word & name() const noexcept
Return name.
const string & note() const noexcept
Return the optional note.
static Ostream & writeDivider(Ostream &os)
Write the standard file section divider.
const std::string buildArch
entry * add(entry *entryPtr, bool mergeEntry=false)
Add a new entry.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const
static bool readHeader(IOobject &io, Istream &is)
const objectRegistry & db() const noexcept
Return the local objectRegistry.