Go to the documentation of this file.
38 const bool stripComments
55 const bool stripComments
70 const bool stripComments
85 const bool stripComments
107 const bool stripComments
114 this->
expand(dict, stripComments);
132 const bool ok = (writeEmpty || !empty());
136 if (!keyword.empty())
138 os.writeKeyword(keyword);
146 tok.
setType(token::tokenType::VERBATIM);
static exprString getEntry(const word &keyword, const dictionary &dict, const bool stripComments=true)
A class for handling words, derived from Foam::string.
void inplaceTrim(std::string &s)
Trim leading and trailing whitespace inplace.
auto key(const Type &t) -> typename std::enable_if< std::is_enum< Type >::value, typename std::underlying_type< Type >::type >::type
A token holds an item read from Istream.
static exprString getOptional(const word &keyword, const dictionary &dict, const bool stripComments=true)
void inplaceRemoveComments(std::string &s)
Remove C/C++ comments inplace.
void inplaceExpand(std::string &s, const HashTable< string > &mapping, const char sigil='$')
void expand(const dictionary &dict, const bool stripComments=true)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
OBJstream os(runTime.globalPath()/outputName)
bool readEntry(const word &keyword, const dictionary &dict, bool mandatory=true, const bool stripComments=true)
bool writeEntry(const word &keyword, Ostream &os, bool writeEmpty=false) const
A variant of Foam::string with expansion of dictionary variables into a comma-separated form.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
static void inplaceExpand(std::string &str, const dictionary &dict, const bool stripComments=true)
string expand(const std::string &s, const HashTable< string > &mapping, const char sigil='$')
bool setType(const tokenType tokType) noexcept
Change the token type, for similar types.
void trim()
Inplace trim leading and trailing whitespace.