45 namespace functionEntries
61 primitiveEntryIstream,
79 primitiveEntryIstream,
98 primitiveEntryIstream,
132 const bool mandatory,
137 const auto* rioPtr = isA<regIOobject>(parentDict.
topDict());
141 rioPtr && rioPtr->global()
166 parentDict.
read(ifs);
180 <<
"Cannot open include file " 181 << (ifs.name().size() ? ifs.name() : rawName)
182 <<
" while reading dictionary " << parentDict.
relativeName()
191 const bool mandatory,
197 const auto* rioPtr = isA<regIOobject>(parentDict.
topDict());
201 rioPtr && rioPtr->global()
226 entry.
read(parentDict, ifs);
240 <<
"Cannot open include file " 241 << (ifs.name().size() ? ifs.name() : rawName)
242 <<
" while reading dictionary " << parentDict.
relativeName()
A class for handling file names.
virtual const fileName & name() const
The name of the stream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
bool read(Istream &is)
Read dictionary from Istream (discards the header). Reads entries until EOF or when the first token i...
A list of keyword definitions, which are a keyword followed by a number of values (eg...
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
constexpr char nl
The newline '\n' character (0x0a)
refPtr< fileOperation > fileHandler(std::nullptr_t)
Delete current file handler - forwards to fileOperation::handler()
static std::string path(const std::string &str)
Return directory path name (part before last /)
static bool isAbsolute(const std::string &str)
Return true if filename starts with a '/' or '\' or (windows-only) with a filesystem-root.
static label worldComm
Communicator for all ranks. May differ from commGlobal() if local worlds are in use.
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
A keyword and a list of tokens comprise a primitiveEntry. A primitiveEntry can be read...
static bool execute(dictionary &parentDict, Istream &is)
Include file (if it exists) in a sub-dict context.
const dictionary & topDict() const
Return the top of the tree.
static fileName resolveFile(const fileName &dir, const fileName &f, const dictionary &dict)
Expand include fileName and return.
void inplaceExpand(std::string &s, const HashTable< string > &mapping, const char sigil='$')
Inplace expand occurrences of variables according to the mapping. Does not use environment values...
virtual void addWatch()
Add file watch on object (if registered and READ_IF_MODIFIED)
virtual const dictionary & dict() const
This entry is not a dictionary, calling this function generates a FatalError.
fileName relativeName(const bool caseTag=false) const
The dictionary name relative to the case.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
static bool execute(const bool mandatory, dictionary &parentDict, Istream &is)
Include file in a sub-dict context.
Macros for easy insertion into member function selection tables.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
messageStream Info
Information stream (stdout output on master, null elsewhere)
addNamedToMemberFunctionSelectionTable(functionEntry, calcEntry, execute, dictionaryIstream, calc)
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
static bool log
Report to stdout which file is included.
virtual bool read(const dictionary &dict, Istream &is)
Read tokens from the given stream.
A keyword and a list of tokens is an 'entry'.
IOerror FatalIOError
Error stream (stdout output on all processes), with additional 'FOAM FATAL IO ERROR' header text and ...