A list of keyword definitions, which are a keyword followed by a number of values (eg, words and numbers) or by a sub-dictionary. Since the dictionary format is used extensively throughout OpenFOAM for input/output files, there are many examples of its use. More...
#include <dictionary.H>


Classes | |
| class | Searcher |
| Generic const/non-const dictionary entry searcher. More... | |
Public Types | |
| typedef Searcher< true > | const_searcher |
| Searcher with const access. | |
| typedef Searcher< false > | searcher |
| Searcher with non-const access. | |
| Public Types inherited from UILList< DLListBase, T > | |
| typedef T | value_type |
| Type of values stored. | |
| typedef T * | pointer |
| Pointer for value_type. | |
| typedef const T * | const_pointer |
| Const pointer for value_type. | |
| typedef T & | reference |
| Reference for value_type. | |
| typedef const T & | const_reference |
| Const reference for value_type. | |
| typedef label | size_type |
| The type that can represent the container size. | |
| typedef label | difference_type |
| The difference between iterator objects. | |
| using | base_iterator |
| using | const_base_iterator |
Public Member Functions | |
| ClassName ("dictionary") | |
| dictionary () | |
| Default construct, a top-level empty dictionary. | |
| dictionary (const fileName &name) | |
| Construct top-level empty dictionary with given name. | |
| dictionary (const fileName &name, const dictionary &parentDict, Istream &is, bool keepHeader=false) | |
| Construct given the entry name, parent dictionary and Istream, reading entries until EOF, optionally keeping the header. | |
| dictionary (Istream &is) | |
| Construct top-level dictionary from Istream (discards the header). Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character. | |
| dictionary (Istream &is, bool keepHeader) | |
| Construct top-level dictionary from Istream, reading entries until EOF, optionally keeping the header. | |
| dictionary (const dictionary &parentDict, const dictionary &dict) | |
| Copy construct given the parent dictionary. | |
| dictionary (const dictionary &dict) | |
| Copy construct top-level dictionary. | |
| dictionary (const dictionary *dict) | |
| Construct top-level dictionary as copy from pointer to dictionary. | |
| dictionary (const dictionary &parentDict, dictionary &&dict) | |
| Move construct for given parent dictionary. | |
| dictionary (dictionary &&dict) | |
| Move construct top-level dictionary. | |
| autoPtr< dictionary > | clone () const |
| Construct and return clone. | |
| virtual | ~dictionary () |
| Destructor. | |
| const fileName & | name () const noexcept |
| The dictionary name. | |
| fileName & | name () noexcept |
| The dictionary name for modification (use with caution). | |
| word | dictName () const |
| The local dictionary name (final part of scoped name). | |
| fileName | relativeName (const bool caseTag=false) const |
| The dictionary name relative to the case. | |
| bool | isNullDict () const noexcept |
| The dictionary is actually dictionary::null (root dictionary). | |
| const dictionary & | parent () const noexcept |
| Return the parent dictionary. | |
| const dictionary & | topDict () const |
| Return the top of the tree. | |
| label | startLineNumber () const |
| Return line number of first token in dictionary. | |
| label | endLineNumber () const |
| Return line number of last token in dictionary. | |
| SHA1Digest | digest () const |
| Return the SHA1 digest of the dictionary contents. | |
| tokenList | tokens () const |
| Return the dictionary as a list of tokens. | |
| const entry * | findEntry (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find an entry (const access) with the given keyword. | |
| entry * | findEntry (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) |
| Find an entry (non-const access) with the given keyword. | |
| bool | found (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find an entry (const access) with the given keyword. | |
| const entry * | findScoped (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Search for a scoped entry (const access) with the given keyword. | |
| const dictionary * | findDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a sub-dictionary pointer if present (and it is a dictionary) otherwise return nullptr. | |
| dictionary * | findDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) |
| Find and return a sub-dictionary pointer if present (and it is a dictionary) otherwise return nullptr. | |
| ITstream * | findStream (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return an entry stream if present (and it is a stream) otherwise return nullptr. | |
| const entry & | lookupEntry (const word &keyword, enum keyType::option matchOpt) const |
| Search for an entry (const access) with the given keyword. | |
| ITstream & | lookup (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return an entry data stream. FatalIOError if not found, or not a stream. | |
| template<class T> | |
| T | get (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T. FatalIOError if not found, or if the number of tokens is incorrect. | |
| template<class T> | |
| T | getOrDefault (const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T, or return the given default value. FatalIOError if it is found and the number of tokens is incorrect. | |
| template<class T> | |
| T | getOrAdd (const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) |
| Find and return a T, or return the given default value and add it to dictionary. FatalIOError if it is found and the number of tokens is incorrect. | |
| template<class T> | |
| bool | readEntry (const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX, IOobjectOption::readOption readOpt=IOobjectOption::MUST_READ) const |
| Find entry and assign to T val. FatalIOError if it is found and the number of tokens is incorrect, or it is mandatory and not found. | |
| template<class T> | |
| bool | readIfPresent (const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const |
| Find an entry if present, and assign to T val. FatalIOError if it is found and the number of tokens is incorrect. | |
| template<class T, class Predicate> | |
| T | getCheck (const word &keyword, const Predicate &pred, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T with additional checking FatalIOError if not found, or if the number of tokens is incorrect. | |
| template<class T, class Predicate> | |
| T | getCheckOrDefault (const word &keyword, const T &deflt, const Predicate &pred, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T, or return the given default value. FatalIOError if it is found and the number of tokens is incorrect. | |
| template<class T, class Predicate> | |
| T | getCheckOrAdd (const word &keyword, const T &deflt, const Predicate &pred, enum keyType::option matchOpt=keyType::REGEX) |
| Find and return a T, or return the given default value and add it to dictionary. FatalIOError if it is found and the number of tokens is incorrect. | |
| template<class T, class Predicate> | |
| bool | readCheck (const word &keyword, T &val, const Predicate &pred, enum keyType::option matchOpt=keyType::REGEX, IOobjectOption::readOption readOpt=IOobjectOption::MUST_READ) const |
| Find entry and assign to T val. FatalIOError if it is found and the number of tokens is incorrect, or it is mandatory and not found. | |
| template<class T, class Predicate> | |
| bool | readCheckIfPresent (const word &keyword, T &val, const Predicate &pred, enum keyType::option matchOpt=keyType::REGEX) const |
| Find an entry if present, and assign to T val. FatalIOError if it is found and the number of tokens is incorrect. | |
| const dictionary & | subDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a sub-dictionary. | |
| dictionary & | subDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) |
| Find and return a sub-dictionary for manipulation. | |
| dictionary & | subDictOrAdd (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) |
| Find and return a sub-dictionary for manipulation. | |
| dictionary | subOrEmptyDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX, const bool mandatory=false) const |
| Find and return a sub-dictionary as a copy, otherwise return an empty dictionary. | |
| const dictionary & | optionalSubDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a sub-dictionary, otherwise return this dictionary. | |
| wordList | toc () const |
| Return the table of contents. | |
| wordList | sortedToc () const |
| Return the sorted table of contents. | |
| template<class Compare> | |
| wordList | sortedToc (const Compare &comp) const |
| Return table of contents sorted using the specified comparator. | |
| List< keyType > | keys (bool patterns=false) const |
| Return the list of available keys or patterns. | |
| bool | substituteKeyword (const word &keyword, bool mergeEntry=false) |
| Substitute the given keyword (which is prefixed by '$'). | |
| bool | substituteScopedKeyword (const word &keyword, bool mergeEntry=false) |
| Substitute the given scoped keyword (which is prefixed by '$'). | |
| entry * | add (entry *entryPtr, bool mergeEntry=false) |
| Add a new entry. | |
| entry * | add (const entry &e, bool mergeEntry=false) |
| Add an entry. | |
| entry * | add (const keyType &k, const word &v, bool overwrite=false) |
| Add a word entry. | |
| entry * | add (const keyType &k, const string &v, bool overwrite=false) |
| Add a string entry. | |
| entry * | add (const keyType &k, const label v, bool overwrite=false) |
| Add a label entry. | |
| entry * | add (const keyType &k, const scalar v, bool overwrite=false) |
| Add a scalar entry. | |
| entry * | add (const keyType &k, const dictionary &d, bool mergeEntry=false) |
| Add a dictionary entry. | |
| template<class T> | |
| entry * | add (const keyType &k, const T &v, bool overwrite=false) |
| Add a T entry. | |
| entry * | set (entry *entryPtr) |
| Assign a new entry, overwriting any existing entry. | |
| entry * | set (const entry &e) |
| Assign a new entry, overwriting any existing entry. | |
| entry * | set (const keyType &k, const dictionary &v) |
| Assign a dictionary entry, overwriting any existing entry. | |
| entry * | set (const keyType &k, std::nullptr_t) |
| Assign an empty primitive entry, overwriting any existing entry. | |
| entry * | set (const keyType &k, const UList< token > &tokens) |
| Assign a primitive entry from a list of tokens, overwriting any existing entry. | |
| entry * | set (const keyType &k, List< token > &&tokens) |
| Assign a primitive entry from a list of tokens, overwriting any existing entry. | |
| template<class T> | |
| entry * | set (const keyType &k, const T &v) |
| Assign a T entry, overwriting any existing entry. | |
| bool | remove (const word &keyword) |
| Remove an entry specified by keyword. | |
| bool | changeKeyword (const keyType &oldKeyword, const keyType &newKeyword, bool overwrite=false) |
| Change the keyword for an entry,. | |
| bool | merge (const dictionary &dict) |
| Merge entries from the given dictionary. | |
| void | clear () |
| Clear the dictionary. | |
| void | transfer (dictionary &dict) |
| Transfer the contents of the argument and annul the argument. | |
| void | checkITstream (const ITstream &is, const word &keyword) const |
| Check after reading if the input token stream has unconsumed tokens remaining or if there were no tokens in the first place. | |
| bool | read (Istream &is) |
| Read dictionary from Istream (discards the header). Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character. | |
| bool | read (Istream &is, bool keepHeader) |
| Read dictionary from Istream (optionally keeping the header) Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character. | |
| void | writeEntry (Ostream &os) const |
| Write sub-dictionary with its dictName as its header. | |
| void | writeEntry (const keyType &keyword, Ostream &os) const |
| Write sub-dictionary with the keyword as its header. | |
| void | writeEntries (Ostream &os, const bool extraNewLine=false) const |
| Write dictionary entries. | |
| void | write (Ostream &os, const bool subDict=true) const |
| Write dictionary, normally with sub-dictionary formatting. | |
| const_searcher | csearch (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Search dictionary for given keyword. | |
| const_searcher | search (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Search dictionary for given keyword. | |
| searcher | search (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) |
| Search dictionary for given keyword. | |
| const_searcher | csearchScoped (const word &keyword, enum keyType::option matchOpt) const |
| Search using scoping. | |
| const_searcher | searchScoped (const word &keyword, enum keyType::option matchOpt) const |
| Search using dot or slash scoping. | |
| searcher | searchScoped (const word &keyword, enum keyType::option matchOpt) |
| Search using dot or slash scoping. | |
| const dictionary * | cfindScopedDict (const fileName &dictPath) const |
| Locate a sub-dictionary using slash-scoping. | |
| const dictionary * | findScopedDict (const fileName &dictPath) const |
| Locate a sub-dictionary using slash-scoping. | |
| dictionary * | findScopedDict (const fileName &dictPath) |
| Locate a sub-dictionary using slash-scoping. | |
| dictionary * | makeScopedDict (const fileName &dictPath) |
| Locate existing or create sub-dictionary using slash-scoping. | |
| const_searcher | csearchCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt=keyType::REGEX) const |
| Search dictionary for given keyword and any compatibility names. | |
| const entry * | findCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt) const |
| Find and return an entry pointer if present, or return a nullptr, using any compatibility names if needed. | |
| bool | foundCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt=keyType::REGEX) const |
| Search dictionary for given keyword and any compatibility names. | |
| const entry & | lookupEntryCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt) const |
| Find and return an entry if present, otherwise FatalIOError, using any compatibility names if needed. | |
| ITstream & | lookupCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return an entry data stream, using any compatibility names if needed. | |
| template<class T> | |
| T | getCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T using any compatibility names if needed. FatalIOError if not found, or if there are excess tokens. | |
| template<class T> | |
| T | getOrDefaultCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const |
| Find and return a T, or return the given default value using any compatibility names if needed. | |
| template<class T> | |
| bool | readCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, T &val, enum keyType::option matchOpt=keyType::REGEX, IOobjectOption::readOption readOpt=IOobjectOption::MUST_READ) const |
| Find entry and assign to T val using any compatibility names if needed. FatalIOError if there are excess tokens. | |
| template<class T> | |
| bool | readIfPresentCompat (const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, T &val, enum keyType::option matchOpt=keyType::REGEX) const |
| Find an entry if present, and assign to T val using any compatibility names if needed. FatalIOError if it is found and there are excess tokens. | |
| void | operator= (const dictionary &rhs) |
| Copy assignment. | |
| void | operator+= (const dictionary &rhs) |
| Include entries from the given dictionary. | |
| void | operator|= (const dictionary &rhs) |
| Conditionally include entries from the given dictionary. | |
| void | operator<<= (const dictionary &rhs) |
| Unconditionally include entries from the given dictionary. | |
| bool | getBool (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<bool>(const word&, keyType::option). | |
| label | getLabel (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<label>(const word&, keyType::option). | |
| scalar | getScalar (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<scalar>(const word&, keyType::option). | |
| string | getString (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<string>(const word&, keyType::option). | |
| word | getWord (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<word>(const word&, keyType::option). | |
| fileName | getFileName (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as get<fileName>(const word&, keyType::option). | |
| bool | isDict (const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const |
| Check for existence of a sub-dictionary. Generally prefer findDict() for more flexibility. | |
| template<class T> | |
| T | lookupOrDefault (const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const |
| Same as getOrDefault(). | |
| template<class T> | |
| T | lookupOrAddDefault (const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) |
| Same as getOrAdd(). | |
| ITstream & | operator[] (const word &keyword) const |
| Deprecated(2018-07) - use lookup() method. | |
| bool | found (const word &keyword, bool recursive, bool patternMatch=true) const |
| Deprecated(2018-10). | |
| entry * | lookupEntryPtr (const word &keyword, bool recursive, bool patternMatch) |
| Deprecated(2018-10). | |
| const entry * | lookupEntryPtr (const word &keyword, bool recursive, bool patternMatch) const |
| Deprecated(2018-10). | |
| const entry * | lookupScopedEntryPtr (const word &keyword, bool recursive, bool patternMatch) const |
| Deprecated(2018-10). | |
| const dictionary * | subDictPtr (const word &keyword) const |
| Deprecated(2018-10). | |
| dictionary * | subDictPtr (const word &keyword) |
| Deprecated(2018-10) Find and return a sub-dictionary pointer if present. | |
| const entry & | lookupEntry (const word &keyword, bool recursive, bool patternMatch) const |
| Deprecated(2018-10). | |
| ITstream & | lookup (const word &keyword, bool recursive, bool patternMatch=true) const |
| Deprecated(2018-10). | |
| template<class T> | |
| T | lookupOrDefault (const word &keyword, const T &deflt, bool recursive, bool patternMatch=true) const |
| Deprecated(2018-10). | |
| template<class T> | |
| T | lookupOrAddDefault (const word &keyword, const T &deflt, bool recursive, bool patternMatch=true) |
| Deprecated(2018-10). | |
| template<class T> | |
| bool | readIfPresent (const word &keyword, T &val, bool recursive, bool patternMatch=true) const |
| Deprecated(2018-10). | |
| template<class T> | |
| T | lookupType (const word &keyword, bool recursive=false, bool patternMatch=true) const |
| Deprecated(2018-10) find and return a T. | |
| template<class Compare> | |
| Foam::wordList | sortedToc (const Compare &comp) const |
| template<class T> | |
| Foam::entry * | add (const keyType &k, const T &v, bool overwrite) |
| template<class T> | |
| Foam::entry * | set (const keyType &k, const T &v) |
| Public Member Functions inherited from ILList< DLListBase, T > | |
| ILList ()=default | |
| Default construct. | |
| ILList (T *item) | |
| Construct and add initial item pointer. | |
| ILList (Istream &is) | |
| Construct from Istream. | |
| ILList (const ILList< DLListBase, T > &lst) | |
| Copy construct using the 'clone()' method for each element. | |
| ILList (ILList< DLListBase, T > &&lst) | |
| Move construct. | |
| ILList (const ILList< DLListBase, T > &lst, const CloneArg &cloneArg) | |
| Copy constructor with additional argument for clone 'clone()'. | |
| ILList (Istream &is, const INew &inew) | |
| Construct from Istream using given Istream constructor class. | |
| ~ILList () | |
| Destructor. Calls clear(). | |
| void | clear () |
| Clear the contents of the list. | |
| void | pop_front (label n=1) |
| Remove first element(s) from the list (deletes pointers). | |
| bool | erase (T *item) |
| Remove the specified element from the list and delete it. | |
| void | transfer (ILList< DLListBase, T > &lst) |
| Transfer the contents of the argument into this List and annul the argument list. | |
| void | operator= (const ILList< DLListBase, T > &lst) |
| Copy assignment using the 'clone()' method for each element. | |
| void | operator= (ILList< DLListBase, T > &&lst) |
| Move assignment. | |
| Public Member Functions inherited from UILList< DLListBase, T > | |
| UILList ()=default | |
| Default construct. | |
| UILList (T *item) | |
| Construct and add initial item pointer. | |
| UILList (const UILList< DLListBase, T > &list) | |
| Construct as copy. | |
| T * | front () |
| The first entry in the list. | |
| const T * | front () const |
| The first entry in the list (const access). | |
| T * | back () |
| The last entry in the list. | |
| const T * | back () const |
| The last entry in the list (const access). | |
| T * | removeHead () |
| Remove and return head. | |
| T * | remove (T *item) |
| Remove and return element. | |
| T * | remove (iterator &iter) |
| Remove and return item specified by iterator. | |
| void | operator= (const UILList< DLListBase, T > &lst) |
| Copy assignment. | |
| bool | operator== (const UILList< DLListBase, T > &lst) const |
| Equality. True both lists are element-wise equal. | |
| bool | operator!= (const UILList< DLListBase, T > &lst) const |
| The opposite of the equality operation. Takes linear time. | |
| Ostream & | writeList (Ostream &os, const label shortLen=0) const |
| Write UILList with line-breaks when length exceeds shortLen. | |
| iterator | begin () |
| Iterator to first item in list with non-const access. | |
| const_iterator | cbegin () const |
| Iterator to first item in list with const access. | |
| reverse_iterator | rbegin () |
| Iterator to last item in list with non-const access. | |
| const_reverse_iterator | crbegin () const |
| Iterator to last item in list with const access. | |
| const_iterator | begin () const |
| Iterator to first item in list with const access. | |
| const_reverse_iterator | rbegin () const |
| Iterator to last item in list with const access. | |
| const iterator & | end () |
| End of list for forward iterators. | |
| const const_iterator & | cend () const |
| End of list for forward iterators. | |
| const reverse_iterator & | rend () |
| End of list for reverse iterators. | |
| const const_reverse_iterator & | crend () const |
| End of list for reverse iterators. | |
| const const_iterator & | end () const |
| End of list for forward iterators. | |
| const const_reverse_iterator & | rend () const |
| End of list for reverse iterators. | |
| T * | first () |
| The first entry in the list. | |
| const T * | first () const |
| The first entry in the list (const access). | |
| T * | last () |
| The last entry in the list. | |
| const T * | last () const |
| The last entry in the list (const access). | |
| Public Member Functions inherited from DLListBase | |
| DLListBase ()=default | |
| Default construct. | |
| DLListBase (const DLListBase &)=delete | |
| No copy construct. | |
| void | operator= (const DLListBase &)=delete |
| No copy assignment. | |
| ~DLListBase ()=default | |
| Destructor. | |
| bool | empty () const noexcept |
| True if the list is empty. | |
| label | size () const noexcept |
| The number of elements in list. | |
| link * | front () |
| Return first entry. | |
| const link * | front () const |
| Return const access to first entry. | |
| link * | back () |
| Return last entry. | |
| const link * | back () const |
| Return const access to last entry. | |
| void | push_front (link *item) |
| Add at front of list. | |
| void | push_back (link *item) |
| Add at back of list. | |
| bool | swapUp (link *item) |
| Swap this element with the one above unless it is at the top. | |
| bool | swapDown (link *item) |
| Swap this element with the one below unless it is at the bottom. | |
| link * | removeHead () |
| Remove and return first entry. | |
| link * | remove (link *item) |
| Remove and return element. | |
| link * | remove (iterator &iter) |
| Remove and return element specified by iterator. | |
| link * | replace (link *oldLink, link *newLink) |
| Replace oldLink with newLink and return element. | |
| link * | replace (iterator &oldIter, link *newitem) |
| Replace oldIter with newItem and return element. | |
| void | clear () |
| Clear the list. | |
| void | swap (DLListBase &lst) |
| Swap the contents of the list. | |
| void | transfer (DLListBase &lst) |
| Transfer the contents of the argument into this list and annul the argument list. | |
| iterator | begin () |
| Iterator to first item in list with non-const access. | |
| const_iterator | cbegin () const |
| Iterator to first item in list with const access. | |
| const_iterator | crbegin () const |
| Iterator to last item in list with const access. | |
| const iterator & | end () |
| End of list for iterators. | |
| const const_iterator & | cend () const |
| End of list for iterators. | |
| const const_iterator & | crend () const |
| End of list for reverse iterators. | |
| link * | first () |
| Return first entry. | |
| const link * | first () const |
| Return const access to first entry. | |
| link * | last () |
| Return last entry. | |
| const link * | last () const |
| Return const access to last entry. | |
| void | prepend (link *item) |
| Add at front of list. | |
| void | append (link *item) |
| Add at back of list. | |
Static Public Member Functions | |
| static int | reportOptional () noexcept |
| Return the state of reporting optional (default) entries. | |
| static int | reportOptional (const int level) noexcept |
| Change the state of reporting optional (default) entries. | |
| static autoPtr< dictionary > | New (Istream &is) |
| Construct top-level dictionary on freestore from Istream. | |
Public Attributes | |
| friend | const_searcher |
| Declare friendship with the searcher classes. | |
| friend | searcher |
Static Public Attributes | |
| static int | writeOptionalEntries |
| Report optional keywords and values if not present in dictionary. | |
| static const dictionary | null |
| An empty dictionary, which is also the parent for all dictionaries. | |
| static refPtr< OSstream > | reportingOutput |
| Output location when reporting default values. | |
Friends | |
| class | entry |
| Declare friendship with the entry class for IO. | |
| Istream & | operator>> (Istream &is, dictionary &dict) |
| Read dictionary from Istream. | |
| Ostream & | operator<< (Ostream &os, const dictionary &dict) |
| Write dictionary to Ostream. | |
Additional Inherited Members | |
| Protected Member Functions inherited from DLListBase | |
| template<class IteratorType> | |
| IteratorType | iterator_first () const |
| Return iterator to first item or end-iterator if list is empty. | |
| template<class IteratorType> | |
| IteratorType | iterator_last () const |
| Return iterator to last item or end-iterator if list is empty. | |
| Static Protected Member Functions inherited from DLListBase | |
| template<class IteratorType> | |
| static const IteratorType & | iterator_end () |
| Factory method to return an iterator end. | |
| template<class IteratorType> | |
| static const IteratorType & | iterator_rend () |
| Factory method to return an iterator reverse end. | |
A list of keyword definitions, which are a keyword followed by a number of values (eg, words and numbers) or by a sub-dictionary. Since the dictionary format is used extensively throughout OpenFOAM for input/output files, there are many examples of its use.
Dictionary keywords are a plain word or a pattern (regular expression). The general order for searching is as follows:
The dictionary class is the base class for IOdictionary and also serves as a bootstrap dictionary for the objectRegistry data dictionaries.
'$' syntax familiar from shell programming. Similarly, the '/' separator is used when referencing sub-dictionary entries:'/' anchor specifies that the path starts from the top-level entry. It is also possible to use the '${}' syntax for clarity.For example,
key1 val1;
key2 $key1; // Use key1 value from current scope
key3 $./key1; // Use key1 value from current scope
subdict1
{
key1 val1b;
key2 $../key1; // Use key1 value from parent
subdict2
{
key2 val2;
key3 $../../key1; // Use key1 value from grandparent
}
}
key4 $/subdict1/subdict2/key3; // Lookup with absolute scoping
Prior to OpenFOAM-v1712, a dot-scoping (.) syntax was used, which is still supported (AUG-2023) but deprecated in favour of the less ambiguous slash-scoping (/) syntax. With dot-scoping, an initial '^' anchor, or an initial (:), was used to specify that the path starts from the top-level entry.
Definition at line 130 of file dictionary.H.
| typedef Searcher<true> const_searcher |
Searcher with const access.
Definition at line 325 of file dictionary.H.
Searcher with non-const access.
Definition at line 330 of file dictionary.H.
| dictionary | ( | ) |
Default construct, a top-level empty dictionary.
Definition at line 68 of file dictionary.C.
References dictionary(), and null.
Referenced by add(), add(), baseIOdictionary::baseIOdictionary(), baseIOdictionary::baseIOdictionary(), caseInfo::caseInfo(), cellSizeFunction::cellSizeFunction(), cfindScopedDict(), dictionaryEntry::clone(), faceAreaWeightModel::coeffDict(), adjointRASModel::coeffDict(), relaxationModel::coeffDict(), regionFaModel::coeffs(), regionModel::coeffs(), cellSizeFunction::coeffsDict(), surfaceCellSizeFunction::coeffsDict(), csearchScoped(), cellSizeFunction::declareRunTimeSelectionTable(), faceAreaWeightModel::declareRunTimeSelectionTable(), adjointRASModel::declareRunTimeSelectionTable(), initialPointsMethod::declareRunTimeSelectionTable(), radiationModel::declareRunTimeSelectionTable(), liquidFilmBase::declareRunTimeSelectionTable(), pyrolysisModel::declareRunTimeSelectionTable(), thermalBaffleModel::declareRunTimeSelectionTable(), relaxationModel::declareRunTimeSelectionTable(), SRFModel::declareRunTimeSelectionTable(), surfaceCellSizeFunction::declareRunTimeSelectionTable(), initialPointsMethod::detailsDict(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), faceAreaWeightModel::faceAreaWeightModel(), fieldDictionary::fieldDictionary(), findDict(), findScopedDict(), properties::foundObjectProperty(), properties::getObjectDict(), properties::getObjectProperty(), properties::getObjectResult(), properties::getObjectResultDict(), properties::hasResultObject(), properties::hasResultObjectEntry(), initialPointsMethod::initialPointsMethod(), liquidFilmBase::liquidFilmBase(), liquidFilmModel::liquidFilmModel(), makeScopedDict(), merge(), cellSizeFunction::New(), faceAreaWeightModel::New(), initialPointsMethod::New(), radiationModel::New(), radiationModel::New(), liquidFilmBase::New(), pyrolysisModel::New(), thermalBaffleModel::New(), relaxationModel::New(), surfaceCellSizeFunction::New(), properties::objectResultEntries(), properties::objectResultType(), operator+=(), operator<<, operator<<=(), baseIOdictionary::operator=(), operator=(), caseInfo::operator=(), liquidFilmBase::operator=(), operator>>, operator|=(), optionalSubDict(), properties::propertyDict(), pyrolysisModel::pyrolysisModel(), radiationModel::radiationModel(), caseInfo::read(), adjointRASModel::read(), pyrolysisModel::read(), regionModel::read(), regionModel::read(), thermalBaffleModel::read(), regionFaModel::regionFaModel(), regionModel::regionModel(), relaxationModel::relaxationModel(), set(), set(), set(), properties::setObjectProperty(), properties::setObjectResult(), sortedToc(), subDictOrAdd(), subDictPtr(), subDictPtr(), subOrEmptyDict(), surfaceCellSizeFunction::surfaceCellSizeFunction(), thermalBaffleModel::thermalBaffleModel(), topDict(), transfer(), caseInfo::TypeName(), liquidFilmModel::TypeName(), regionModel::TypeName(), caseInfo::write(), properties::writeAllResultEntries(), caseInfo::writeFileDicts(), caseInfo::writeFunctionObjects(), caseInfo::writeMeshStats(), caseInfo::writeMeta(), caseInfo::writePatches(), caseInfo::writeRegisteredDicts(), properties::writeResultEntries(), baseIOdictionary::~baseIOdictionary(), and caseInfo::~caseInfo().

|
explicit |
Construct top-level empty dictionary with given name.
Definition at line 75 of file dictionary.C.
References dictionary(), name(), and null.

| dictionary | ( | const fileName & | name, |
| const dictionary & | parentDict, | ||
| Istream & | is, | ||
| bool | keepHeader = false ) |
Construct given the entry name, parent dictionary and Istream, reading entries until EOF, optionally keeping the header.
Definition at line 27 of file dictionaryIO.C.
References dictionary(), name(), and read().

| dictionary | ( | Istream & | is | ) |
Construct top-level dictionary from Istream (discards the header). Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character.
Definition at line 42 of file dictionaryIO.C.
References dictionary().

| dictionary | ( | Istream & | is, |
| bool | keepHeader ) |
Construct top-level dictionary from Istream, reading entries until EOF, optionally keeping the header.
Definition at line 48 of file dictionaryIO.C.
References dictionary(), name(), null, read(), and entry::resetInputMode().

| dictionary | ( | const dictionary & | parentDict, |
| const dictionary & | dict ) |
Copy construct given the parent dictionary.
Definition at line 82 of file dictionary.C.
References dict, dictionary(), e, entry, name(), and autoPtr< T >::New().

| dictionary | ( | const dictionary & | dict | ) |
Copy construct top-level dictionary.
Definition at line 105 of file dictionary.C.
References dict, dictionary(), e, entry, name(), autoPtr< T >::New(), and null.

|
explicit |
Construct top-level dictionary as copy from pointer to dictionary.
A null pointer is treated like an empty dictionary.
Definition at line 127 of file dictionary.C.
References dict, dictionary(), null, and operator=().

| dictionary | ( | const dictionary & | parentDict, |
| dictionary && | dict ) |
Move construct for given parent dictionary.
Definition at line 139 of file dictionary.C.
References fileName::concat(), dict, dictionary(), name(), and transfer().

| dictionary | ( | dictionary && | dict | ) |
Move construct top-level dictionary.
Definition at line 153 of file dictionary.C.
References dict, dictionary(), null, and transfer().

|
virtual |
Destructor.
Definition at line 173 of file dictionary.C.
| ClassName | ( | "dictionary" | ) |
|
inlinestaticnoexcept |
Return the state of reporting optional (default) entries.
0: no reporting, 1: report, 2: fatal if not set
Definition at line 25 of file dictionaryI.H.
References Foam::noexcept, and writeOptionalEntries.
|
inlinestaticnoexcept |
Change the state of reporting optional (default) entries.
0: no reporting, 1: report, 2: fatal if not set
Definition at line 31 of file dictionaryI.H.
References writeOptionalEntries.
| Foam::autoPtr< Foam::dictionary > clone | ( | ) | const |
Construct and return clone.
Definition at line 165 of file dictionary.C.
References autoPtr< T >::New().
Referenced by Foam::preservePatchTypes(), and refinementSurfaces::refinementSurfaces().


|
static |
Construct top-level dictionary on freestore from Istream.
Definition at line 62 of file dictionaryIO.C.
References autoPtr< T >::New().

|
inlinenoexcept |
The dictionary name.
Definition at line 41 of file dictionaryI.H.
References Foam::noexcept.
Referenced by baseIOdictionary::baseIOdictionary(), baseIOdictionary::baseIOdictionary(), Foam::copyFilteredDict(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), JobInfo::JobInfo(), dictionaryEntry::name(), dictionaryEntry::name(), Foam::operator>>(), Foam::unitSet(), and codedBase::updateLibrary().

|
inlinenoexcept |
The dictionary name for modification (use with caution).
Definition at line 47 of file dictionaryI.H.
References Foam::noexcept.
|
inline |
The local dictionary name (final part of scoped name).
Definition at line 53 of file dictionaryI.H.
Referenced by faSchemes::faSchemes(), faSchemes::faSchemes(), faSolution::faSolution(), faSolution::faSolution(), fvSchemes::fvSchemes(), fvSchemes::fvSchemes(), fvSolution::fvSolution(), fvSolution::fvSolution(), NURBS3DVolume::NURBS3DVolume(), objective::objective(), dictionaryValue::processDict(), multiFieldValue::read(), schemesLookup::schemesLookup(), schemesLookup::schemesLookup(), solution::solution(), solution::solution(), tolerances::tolerances(), twoPhaseSystem::twoPhaseSystem(), and solution::upgradeSolverDict().

| Foam::fileName relativeName | ( | const bool | caseTag = false | ) | const |
The dictionary name relative to the case.
Uses argList::envRelativePath to obtain FOAM_CASE
| caseTag | replace globalPath with <case> for later use with expand(), or prefix <case> if the file name was not an absolute location |
Definition at line 179 of file dictionary.C.
References argList::envRelativePath(), and name.
Referenced by add(), checkITstream(), csearchCompat(), codeStream::evaluate(), includeEntry::execute(), includeEntry::execute(), includeEtcEntry::execute(), includeEtcEntry::execute(), lookupEntry(), lookupEntryCompat(), merge(), operator+=(), operator<<=(), operator|=(), optionalSubDict(), dictionaryEntry::relativeName(), subDict(), subDict(), subDictOrAdd(), and subOrEmptyDict().


|
inlinenoexcept |
The dictionary is actually dictionary::null (root dictionary).
Definition at line 71 of file dictionaryI.H.
References Foam::noexcept, and null.
|
inlinenoexcept |
Return the parent dictionary.
Definition at line 77 of file dictionaryI.H.
References Foam::noexcept.
Referenced by profiling::create(), profiling::New(), profiling::operator=(), topDict(), and writeEntries().

| const Foam::dictionary & topDict | ( | ) | const |
Return the top of the tree.
Definition at line 185 of file dictionary.C.
References dictionary(), p, and parent().
Referenced by includeEntry::execute(), includeEntry::execute(), includeEtcEntry::execute(), includeEtcEntry::execute(), and codeStream::getFunction().


| Foam::label startLineNumber | ( | ) | const |
Return line number of first token in dictionary.
Definition at line 198 of file dictionary.C.
References DLListBase::empty(), UILList< DLListBase, T >::front(), and startLineNumber().
Referenced by startLineNumber(), dictionaryEntry::startLineNumber(), and codedBase::updateLibrary().


| Foam::label endLineNumber | ( | ) | const |
Return line number of last token in dictionary.
Definition at line 209 of file dictionary.C.
References UILList< DLListBase, T >::back(), DLListBase::empty(), and endLineNumber().
Referenced by endLineNumber(), and dictionaryEntry::endLineNumber().


| Foam::SHA1Digest digest | ( | ) | const |
| Foam::tokenList tokens | ( | ) | const |
Return the dictionary as a list of tokens.
Definition at line 234 of file dictionary.C.
References e, entry, os(), and ITstream::parse().
Referenced by add(), set(), and set().


|
inline |
Find an entry (const access) with the given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 83 of file dictionaryI.H.
References csearch().
Referenced by boundaryRadiationProperties::boundaryRadiationProperties(), dynamicCodeContext::findEntry(), found(), genericFaePatchField< Type >::genericFaePatchField(), genericFaPatchField< Type >::genericFaPatchField(), genericFvPatchField< Type >::genericFvPatchField(), genericFvsPatchField< Type >::genericFvsPatchField(), lookupEntry(), lookupEntryPtr(), lookupEntryPtr(), refinementSurfaces::refinementSurfaces(), caseInfo::writeFileDicts(), and caseInfo::writeRegisteredDicts().


|
inline |
Find an entry (non-const access) with the given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 93 of file dictionaryI.H.
References csearch(), and entry.

|
inline |
Find an entry (const access) with the given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 103 of file dictionaryI.H.
References findEntry().
Referenced by equationInitialResidualCondition::apply(), equationMaxIterCondition::apply(), DAC< CompType, ThermoType >::DAC(), designVariablesUpdate::designVariablesUpdate(), Foam::dimensionedConstant(), DRG< CompType, ThermoType >::DRG(), DRGEP< CompType, ThermoType >::DRGEP(), found(), properties::foundObjectProperty(), subModelBase::getModelDict(), subModelBase::getModelProperty(), adjointSolver::getObjectiveSensitivities(), properties::getObjectResult(), refinementParameters::getZoneInfo(), properties::hasResultObject(), properties::hasResultObjectEntry(), incompressibleInterPhaseTransportModel< Mixture >::incompressibleInterPhaseTransportModel(), oversetFvPatchField< Type >::initEvaluate(), solverInfo::initialiseResidualField(), ISAT< CompType, ThermoType >::ISAT(), waveModel::New(), properties::objectResultEntries(), properties::objectResultType(), PFA< CompType, ThermoType >::PFA(), Foam::preservePatchTypes(), tolerances::read(), volumetricBSplinesDesignVariables::readBounds(), levelSetDesignVariables::readField(), topODesignVariables::readField(), functionObjectList::readFunctionObject(), refinementSurfaces::refinementSurfaces(), rigidBodyMeshMotion::rigidBodyMeshMotion(), rigidBodyMeshMotionSolver::rigidBodyMeshMotionSolver(), rigidBodyModel::rigidBodyModel(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::setCdSigma(), runTimeCondition::setConditionDict(), subModelBase::setModelProperty(), properties::setObjectResult(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::setPorosityCoefficient(), sixDoFRigidBodyMotion::sixDoFRigidBodyMotion(), SQPBase::SQPBase(), inverseDistance::update(), solverInfo::updateSolverInfo(), volumetricBSplinesDesignVariables::volumetricBSplinesDesignVariables(), properties::writeResultEntries(), and writer::writeSolution().


|
inline |
Search for a scoped entry (const access) with the given keyword.
Allows scoping using '.'. Special handling for an absolute anchor (^) at start of the keyword and for '..' to ascend into the parent dictionaries.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 113 of file dictionaryI.H.
References csearchScoped().
Referenced by lookupScopedEntryPtr().


|
inline |
Find and return a sub-dictionary pointer if present (and it is a dictionary) otherwise return nullptr.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 123 of file dictionaryI.H.
References csearch().
Referenced by codedMixedFvPatchField< Type >::codeContext(), coordSetWriter::coordSetWriter(), energyTransport::energyTransport(), faMesh::faMesh(), writerCaching::fieldsDict(), properties::foundObjectProperty(), Foam::fileFormats::getFormatOptions(), properties::getObjectDict(), properties::getObjectResultDict(), properties::hasResultObject(), oversetFvPatchField< Type >::initEvaluate(), isDict(), loopControl::loopControl(), loopControl::loopControl(), namedBlock::namedBlock(), namedVertex::namedVertex(), basicChemistryModel::New(), RASModelVariables::New(), laminarModel< BasicTurbulenceModel >::New(), optimisationManager::optimisationManager(), decompositionMethod::optionalRegionDict(), uniformBin::read(), adjointRASModel::read(), regionModel::read(), Time::readDict(), functionObjectList::readFunctionObject(), reader::remapMeshInfo(), Foam::resetFuncsImpl(), Time::setMonitoring(), subDictPtr(), subDictPtr(), surfaceWriter::surfaceWriter(), Foam::debug::switchSet(), blockDescriptor::write(), blockVertex::write(), Foam::writeFuncsImpl(), and writer::writeSolution().


|
inline |
Find and return a sub-dictionary pointer if present (and it is a dictionary) otherwise return nullptr.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 133 of file dictionaryI.H.
References csearch(), and dictionary().

|
inline |
Find and return an entry stream if present (and it is a stream) otherwise return nullptr.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 143 of file dictionaryI.H.
References csearch().
Referenced by solution::upgradeSolverDict().


| const Foam::entry & lookupEntry | ( | const word & | keyword, |
| enum keyType::option | matchOpt ) const |
Search for an entry (const access) with the given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode |
Definition at line 346 of file dictionary.C.
References entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, findEntry(), Foam::nl, and relativeName().
Referenced by lduMatrix::preconditioner::getName(), lduMatrix::smoother::getName(), lookup(), lookupEntry(), lduMatrix::preconditioner::New(), and lduMatrix::smoother::New().


| Foam::ITstream & lookup | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return an entry data stream. FatalIOError if not found, or not a stream.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 366 of file dictionary.C.
References lookupEntry().
Referenced by equationMaxIterCondition::apply(), lookup(), multiphaseSystem::multiphaseSystem(), interpolation< Type >::New(), operator[](), cloudSolution::read(), dimensionSet::read(), regionModel::regionModel(), regionModel::regionModel(), twoPhaseSystem::twoPhaseSystem(), and solverInfo::updateSolverInfo().


| T get | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T. FatalIOError if not found, or if the number of tokens is incorrect.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 99 of file dictionaryTemplates.C.
References readEntry(), and Foam::T().
Referenced by geometric::add(), columnFvMeshInfo::addLocalPatches(), adjointRASModel::adjointRASModel(), basicChemistryModel::basicChemistryModel(), betaMaxDarcy::betaMaxDarcy(), CloudFunctionObjectList< CloudType >::CloudFunctionObjectList(), coalCloudList::coalCloudList(), componentDisplacementMotionSolver::componentDisplacementMotionSolver(), betaMax::computeLength(), DAC< CompType, ThermoType >::DAC(), Foam::dimensionedConstant(), directions::directions(), displacementComponentLaplacianFvMotionSolver::displacementComponentLaplacianFvMotionSolver(), displacementLaplacianFvMotionSolver::displacementLaplacianFvMotionSolver(), displacementLaplacianFvMotionSolver::displacementLaplacianFvMotionSolver(), displacementPointSmoothingMotionSolver::displacementPointSmoothingMotionSolver(), displacementPointSmoothingMotionSolver::displacementPointSmoothingMotionSolver(), displacementSmartPointSmoothingMotionSolver::displacementSmartPointSmoothingMotionSolver(), displacementSmartPointSmoothingMotionSolver::displacementSmartPointSmoothingMotionSolver(), argList::displayDoc(), dynamicInkJetFvMesh::dynamicInkJetFvMesh(), elasticityMotionSolver::elasticityMotionSolver(), thermalShell::evolveRegion(), faMesh::faMesh(), FreeStream< CloudType >::FreeStream(), fvDOM::fvDOM(), fvDOM::fvDOM(), graphFunctionObject::graphFunctionObject(), optimisationManager::initialize(), ISAT< CompType, ThermoType >::ISAT(), kinematicSingleLayer::kinematicSingleLayer(), laplacianMotionSolver::laplacianMotionSolver(), Foam::MULES::limiterCorr(), liquidFilmBase::liquidFilmBase(), lookupType(), displacementMeshMoverMotionSolver::meshMover(), mixerFvMesh::mixerFvMesh(), medialAxisMeshMover::move(), multiphaseInterSystem::multiphaseInterSystem(), basicSolidChemistryModel::New(), chemistryReductionMethod< CompType, ThermoType >::New(), chemistryTabulationMethod< CompType, ThermoType >::New(), decompositionMethod::New(), displacementMethod::New(), heatExchangerModel::New(), adjointTurbulenceModel::New(), laminarFlameSpeed::New(), LduMatrix< Type, DType, LUType >::preconditioner::New(), LduMatrix< Type, DType, LUType >::smoother::New(), LduMatrix< Type, DType, LUType >::solver::New(), lduMatrix::solver::New(), waveModel::New(), nullSpace::nullSpace(), NURBS3DVolume::NURBS3DVolume(), NURBS3DVolumeCylindrical::NURBS3DVolumeCylindrical(), objectiveFlowRate::objectiveFlowRate(), objectiveFlowRatePartition::objectiveFlowRatePartition(), objectiveForce::objectiveForce(), objectiveMoment::objectiveMoment(), objectiveNutSqr::objectiveNutSqr(), objectivePartialVolume::objectivePartialVolume(), objectivePowerDissipation::objectivePowerDissipation(), objectiveUniformityCellZone::objectiveUniformityCellZone(), optimisationManager::optimisationManager(), parProfilingSolver::parProfilingSolver(), IOobject::parseHeader(), plane::plane(), pLaplacianMotionSolver::pLaplacianMotionSolver(), powerLawLopesdaCostaZone::powerLawLopesdaCostaZone(), singleDirectionUniformBin::read(), uniformBin::read(), externalCoupled::read(), multiphaseMangrovesSource::read(), multiphaseMangrovesTurbulenceModel::read(), rotorDiskSource::read(), solutionControl::read(), targetCoeffTrim::read(), tolerances::read(), dynamicRefineFvMesh::readDict(), functionObjectList::readFunctionObject(), SIMPLEControl::readIters(), SIMPLEControlSingleRun::readIters(), waveGenerationModel::readWaveAngle(), waveGenerationModel::readWaveHeight(), refinementSurfaces::refinementSurfaces(), regionFaModel::regionFaModel(), regionModel::regionModel(), regionModel::regionModel(), rigidBodyModel::rigidBodyModel(), rpm::rpm(), searchableSurfaceCollection::searchableSurfaceCollection(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::setCdSigma(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::setPorosityCoefficient(), sixDoFRigidBodyMotionSolver::sixDoFRigidBodyMotionSolver(), solidBodyDisplacementLaplacianFvMotionSolver::solidBodyDisplacementLaplacianFvMotionSolver(), solidBodyDisplacementLaplacianFvMotionSolver::solidBodyDisplacementLaplacianFvMotionSolver(), populationBalanceModel::solve(), rigidBodyMeshMotion::solve(), rigidBodyMeshMotionSolver::solve(), MultiComponentPhaseModel< BasePhaseModel, phaseThermo >::solveYi(), SRFModel::SRFModel(), surfaceAlignedSBRStressFvMotionSolver::surfaceAlignedSBRStressFvMotionSolver(), thermalBaffle::thermalBaffle(), thermalBaffle::thermalBaffle(), thermoSingleLayer::thermoSingleLayer(), twoPhaseSystem::twoPhaseSystem(), dynamicRefineFvMesh::updateTopology(), velocityDisplacementMotionSolver::velocityDisplacementMotionSolver(), vibrationShellModel::vibrationShellModel(), WallLocalSpringSliderDashpot< CloudType >::WallLocalSpringSliderDashpot(), ensightWriter::writeCollated(), and ensightWriter::writeCollated().

| T getOrDefault | ( | const word & | keyword, |
| const T & | deflt, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T, or return the given default value. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| deflt | the default value to use |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 140 of file dictionaryTemplates.C.
References checkITstream(), csearch(), entry, entry::stream(), Foam::T(), and writeOptionalEntries.
Referenced by adjointRASModel::adjointRASModel(), adjointSolver::adjointSolver(), adjointSpalartAllmaras::adjointSpalartAllmaras(), basicChemistryModel::basicChemistryModel(), basicThermo::basicThermo(), basicThermo::basicThermo(), basicThermo::basicThermo(), BFGS::BFGS(), combustionModel::combustionModel(), conjugateGradient::conjugateGradient(), constraintProjection::constraintProjection(), csvWriter::csvWriter(), DBFGS::DBFGS(), diffusion< ReactionThermo, ThermoType >::diffusion(), displacementComponentLaplacianFvMotionSolver::displacementComponentLaplacianFvMotionSolver(), dynamicTopODesignVariables::dynamicTopODesignVariables(), EDC< ReactionThermo >::EDC(), ensightSurfaceReader::ensightSurfaceReader(), faMesh::faMesh(), gnuplotWriter::gnuplotWriter(), gradAlpha::gradAlpha(), graphFunctionObject::graphFunctionObject(), incompressiblePrimalSolver::incompressiblePrimalSolver(), MMA::initialize(), isoAlpha::isoAlpha(), ISQP::ISQP(), kinematicSingleLayer::kinematicSingleLayer(), KinematicSurfaceFilm< CloudType >::KinematicSurfaceFilm(), KirchhoffShell::KirchhoffShell(), laminar< ReactionThermo >::laminar(), LBFGS::LBFGS(), levelSetDesignVariables::levelSetDesignVariables(), Foam::MULES::limiter(), Foam::MULES::limiterCorr(), liquidFilmBase::liquidFilmBase(), LocalInteraction< CloudType >::LocalInteraction(), lookupOrDefault(), lookupOrDefault(), MeshedSurface< Face >::MeshedSurface(), MMA::MMA(), tableReader< Type >::New(), nullSpace::nullSpace(), NURBS3DVolume::NURBS3DVolume(), objectiveTopOSolidVolume::objectiveTopOSolidVolume(), objectiveTopOVolume::objectiveTopOVolume(), outletMappedUniformInletFvPatchField< Type >::outletMappedUniformInletFvPatchField(), argList::parse(), pLaplacianMotionSolver::pLaplacianMotionSolver(), plicRDF::plicRDF(), quasiNewton::quasiNewton(), radiationModel::radiationModel(), radiationModel::radiationModel(), rawWriter::rawWriter(), singleDirectionUniformBin::read(), uniformBin::read(), multiFieldValue::read(), radiationModel::read(), sampledSurfaces::read(), SIMPLEControlOpt::read(), solverControl::read(), targetCoeffTrim::read(), adjointSensitivity::readDict(), temperatureDependent::readDict(), reconstructionSchemes::reconstructionSchemes(), refinementSurfaces::refinementSurfaces(), regionFaModel::regionFaModel(), rigidBodyMeshMotion::rigidBodyMeshMotion(), rigidBodyMeshMotionSolver::rigidBodyMeshMotionSolver(), Time::setMonitoring(), propellerInfo::setSampleDiskSurface(), simple::simple(), sixDoFRigidBodyMotionSolver::sixDoFRigidBodyMotionSolver(), populationBalanceModel::solve(), faMatrix< Type >::solve(), faMatrix< scalar >::solve(), fvMatrix< Type >::fvSolver::solve(), rigidBodyMeshMotion::solve(), velocityLaplacianFvMotionSolver::solve(), fvMatrix< Type >::solveCoupled(), shapeDesignVariables::solveMeshMovementEqn(), solver::solver(), fvMatrix< Type >::solveSegregated(), fvMatrix< scalar >::solveSegregated(), fvMatrix< Type >::solveSegregatedOrCoupled(), MultiComponentPhaseModel< BasePhaseModel, phaseThermo >::solveYi(), SQP::SQP(), SR1::SR1(), StandardChemistryModel< ReactionThermo, ThermoType >::StandardChemistryModel(), StandardWallInteraction< CloudType >::StandardWallInteraction(), surfaceAlignedSBRStressFvMotionSolver::surfaceAlignedSBRStressFvMotionSolver(), TDACChemistryModel< ReactionThermo, ThermoType >::TDACChemistryModel(), thermalBaffleModel::thermalBaffleModel(), thermalBaffleModel::thermalBaffleModel(), thermalShell::thermalShell(), thermalShellModel::thermalShellModel(), UnsortedMeshedSurface< Face >::UnsortedMeshedSurface(), inverseDistance::update(), turbulentMixingLengthDissipationRateInletFvPatchScalarField::updateCoeffs(), turbulentMixingLengthFrequencyInletFvPatchScalarField::updateCoeffs(), updateMethod::updateMethod(), dynamicRefineFvMesh::updateTopology(), vibrationShellModel::vibrationShellModel(), viewFactor::viewFactor(), viewFactor::viewFactor(), volumetricBSplinesDesignVariables::volumetricBSplinesDesignVariables(), vtkWriter::vtkWriter(), VTKedgeFormat::write(), ensightWriter::writeCollated(), ensightWriter::writeCollated(), and xmgraceWriter::xmgraceWriter().

| T getOrAdd | ( | const word & | keyword, |
| const T & | deflt, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) |
Find and return a T, or return the given default value and add it to dictionary. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| deflt | the default value to use |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 170 of file dictionaryTemplates.C.
References Foam::add(), checkITstream(), csearch(), entry, entry::stream(), Foam::T(), and writeOptionalEntries.
Referenced by lookupOrAddDefault(), and lookupOrAddDefault().


| bool readEntry | ( | const word & | keyword, |
| T & | val, | ||
| enum keyType::option | matchOpt = keyType::REGEX, | ||
| IOobjectOption::readOption | readOpt = IOobjectOption::MUST_READ ) const |
Find entry and assign to T val. FatalIOError if it is found and the number of tokens is incorrect, or it is mandatory and not found.
| keyword | the keyword to search for |
| val | the value to read into |
| matchOpt | search mode (default: non-recursive with patterns) |
| readOpt | the entry is required/optional (default: MUST_READ) |
Definition at line 294 of file dictionaryTemplates.C.
References checkITstream(), csearch(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, IOobjectOption::isReadRequired(), name, Foam::nl, IOobjectOption::NO_READ, entry::stream(), and Foam::T().
Referenced by fromFile::computeControlPoints(), argList::displayDoc(), ETAB< CloudType >::ETAB(), get(), InflationInjection< CloudType >::InflationInjection(), ISAT< CompType, ThermoType >::ISAT(), KinematicSurfaceFilm< CloudType >::KinematicSurfaceFilm(), multiBandZoneAbsorptionEmission::multiBandZoneAbsorptionEmission(), multiphaseSystem::multiphaseSystem(), decompositionMethod::nDomains(), PairSpringSliderDashpot< CloudType >::PairSpringSliderDashpot(), argList::parse(), PilchErdman< CloudType >::PilchErdman(), anisotropicFilter::read(), combustionModel::read(), multiphaseMangrovesSource::read(), multiphaseMangrovesTurbulenceModel::read(), adjointRASModel::read(), Casson::read(), laplaceFilter::read(), smoothDelta::read(), radiationModel::read(), phasePressureModel::read(), kinematicSingleLayer::read(), thermalBaffle::read(), thermalBaffle::read(), SRFModel::read(), targetCoeffTrim::read(), Arrhenius< ViscousModel >::read(), thermo::readControls(), dynamicRefineFvMesh::readDict(), mapDistributeBase::readDict(), mapDistributePolyMesh::readDict(), constant::readDict(), waveModel::readDict(), irregularMultiDirectional::readDict(), irregularWaveModel::readDict(), regularWaveModel::readDict(), streamFunction::readDict(), waveGenerationModel::readDict(), readIfPresent(), valueAverageBase::readState(), ReitzDiwakar< CloudType >::ReitzDiwakar(), ReitzKHRT< CloudType >::ReitzKHRT(), rigidBodyMeshMotion::rigidBodyMeshMotion(), rigidBodyMeshMotionSolver::rigidBodyMeshMotionSolver(), searchableSurfaceCollection::searchableSurfaceCollection(), reducedUnits::setRefValues(), SingleMixtureFraction< CloudType >::SingleMixtureFraction(), sixDoFRigidBodyMotionSolver::sixDoFRigidBodyMotionSolver(), surfaceFeatures::surfaceFeatures(), thermoCoupleProbes::thermoCoupleProbes(), WallLocalSpringSliderDashpot< CloudType >::WallLocalSpringSliderDashpot(), WallSpringSliderDashpot< CloudType >::WallSpringSliderDashpot(), writer::writeSolution(), and zoneCombustion< ReactionThermo >::zoneCombustion().

| bool readIfPresent | ( | const word & | keyword, |
| T & | val, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find an entry if present, and assign to T val. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| val | the value to read into |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 412 of file dictionaryTemplates.C.
References IOobjectOption::READ_IF_PRESENT, readEntry(), and Foam::T().
Referenced by abaqusWriter::abaqusWriter(), advectiveFvPatchField< Type >::advectiveFvPatchField(), basicThermo::basicThermo(), basicThermo::basicThermo(), basicThermo::basicThermo(), boundaryDataSurfaceReader::boundaryDataSurfaceReader(), valueAverageBase::calc(), cloudSolution::cloudSolution(), betaMax::computeLength(), coordSetWriter::coordSetWriter(), metisDecomp::decomposeSerial(), subModelBase::getBaseProperty(), subModelBase::getBaseProperty(), subModelBase::getModelProperty(), decomposedBlockData::getNumBlocks(), properties::getObjectProperty(), properties::getObjectResult(), refinementParameters::getZoneInfo(), graphFunctionObject::graphFunctionObject(), kinematicSingleLayer::info(), nastranWriter::nastranWriter(), decompositionMethod::nDomains(), decompositionMethod::New(), objectivePartialVolume::objectivePartialVolume(), IOobject::parseHeader(), ParticlePostProcessing< CloudType >::ParticlePostProcessing(), Foam::preservePatchTypes(), randomDecomp::randomDecomp(), singleDirectionUniformBin::read(), DeltaOmegaTildeDelta::read(), IDDESDelta::read(), maxDeltaxyz::read(), PrandtlDelta::read(), SLADelta::read(), vanDriestDelta::read(), mapDistribute::readDict(), Time::readDict(), decomposedBlockData::readHeader(), readIfPresent(), refinementSurfaces::refinementSurfaces(), Time::setControls(), propellerInfo::setSampleDiskSurface(), Time::setTime(), surfaceWriter::surfaceWriter(), surfaceZonesInfo::surfaceZonesInfo(), thermoSingleLayer::thermoSingleLayer(), kinematicSingleLayer::transferPrimaryRegionSourceFields(), updateMethod::updateMethod(), vanDriestDelta::vanDriestDelta(), and x3dWriter::x3dWriter().

| T getCheck | ( | const word & | keyword, |
| const Predicate & | pred, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T with additional checking FatalIOError if not found, or if the number of tokens is incorrect.
| keyword | the keyword to search for |
| pred | the value check predicate |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 112 of file dictionaryTemplates.C.
References readCheck(), and Foam::T().
Referenced by singleDirectionUniformBin::read(), and electricPotential::read().


| T getCheckOrDefault | ( | const word & | keyword, |
| const T & | deflt, | ||
| const Predicate & | pred, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T, or return the given default value. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| deflt | the default value to use |
| pred | the value check predicate |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 201 of file dictionaryTemplates.C.
References checkITstream(), csearch(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, name, entry::stream(), Foam::T(), and writeOptionalEntries.

| T getCheckOrAdd | ( | const word & | keyword, |
| const T & | deflt, | ||
| const Predicate & | pred, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) |
Find and return a T, or return the given default value and add it to dictionary. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| deflt | the default value to use |
| pred | the value check predicate |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 247 of file dictionaryTemplates.C.
References Foam::add(), checkITstream(), csearch(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, name, entry::stream(), Foam::T(), and writeOptionalEntries.

| bool readCheck | ( | const word & | keyword, |
| T & | val, | ||
| const Predicate & | pred, | ||
| enum keyType::option | matchOpt = keyType::REGEX, | ||
| IOobjectOption::readOption | readOpt = IOobjectOption::MUST_READ ) const |
Find entry and assign to T val. FatalIOError if it is found and the number of tokens is incorrect, or it is mandatory and not found.
| keyword | the keyword to search for |
| val | the value to read into |
| pred | the value check predicate |
| matchOpt | search mode (default: non-recursive with patterns) |
| readOpt | the entry is required/optional (default: MUST_READ) |
Definition at line 331 of file dictionaryTemplates.C.
References checkITstream(), csearch(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, IOobjectOption::isReadRequired(), name, Foam::nl, IOobjectOption::NO_READ, entry::stream(), and Foam::T().
Referenced by getCheck(), and readCheckIfPresent().


| bool readCheckIfPresent | ( | const word & | keyword, |
| T & | val, | ||
| const Predicate & | pred, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find an entry if present, and assign to T val. FatalIOError if it is found and the number of tokens is incorrect.
| keyword | the keyword to search for |
| val | the value to read into |
| pred | the value check predicate |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 431 of file dictionaryTemplates.C.
References IOobjectOption::READ_IF_PRESENT, readCheck(), and Foam::T().

| const Foam::dictionary & subDict | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a sub-dictionary.
Fatal if the entry does not exist or is not a sub-dictionary.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 440 of file dictionary.C.
References csearch(), dictionary::Searcher< Const >::dict(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, dictionary::Searcher< Const >::good(), Foam::nl, and relativeName().
Referenced by snappyLayerDriver::addLayers(), adjointSolver::adjointSolver(), adjointSolverManager::adjointSolverManager(), meshState::controlsDict(), meshState::controlsDict(), adjointSolver::designVarsDict(), Foam::dimensionedConstant(), Foam::dimensionedConstant(), displacementPointSmoothingMotionSolver::displacementPointSmoothingMotionSolver(), displacementPointSmoothingMotionSolver::displacementPointSmoothingMotionSolver(), displacementSmartPointSmoothingMotionSolver::displacementSmartPointSmoothingMotionSolver(), displacementSmartPointSmoothingMotionSolver::displacementSmartPointSmoothingMotionSolver(), argList::displayDoc(), dynamicTopODesignVariables::dynamicTopODesignVariables(), faMesh::faMesh(), subModelBase::getModelDict(), subModelBase::getModelProperty(), properties::getObjectDict(), properties::getObjectProperty(), properties::getObjectResult(), refinementParameters::getZoneInfo(), properties::hasResultObjectEntry(), incompressibleTwoPhaseMixture::incompressibleTwoPhaseMixture(), dynamicMultiMotionSolverFvMesh::init(), oversetFvPatchField< Type >::initEvaluate(), viewFactor::initialise(), optimisationManager::initialize(), cloudSolution::integrationSchemes(), cloudSolution::interpolationSchemes(), kinematicSingleLayer::kinematicSingleLayer(), levelSetDesignVariables::levelSetDesignVariables(), liquidFilmBase::liquidFilmBase(), liquidFilmModel::liquidFilmModel(), meshState::meshDict(), meshState::meshDict(), multiBandZoneAbsorptionEmission::multiBandZoneAbsorptionEmission(), multiSolidBodyMotionSolver::multiSolidBodyMotionSolver(), adjointSolverManager::nActiveAdjointSolvers(), basicSolidChemistryModel::New(), LESModel< BasicTurbulenceModel >::New(), waveModel::New(), objectiveManager::objectiveManager(), properties::objectResultEntries(), properties::objectResultNames(), properties::objectResultType(), phaseSystem::phaseSystem(), Foam::preservePatchTypes(), pyrolysisModelCollection::pyrolysisModelCollection(), runTimeControl::read(), multiphaseMangrovesSource::read(), multiphaseMangrovesTurbulenceModel::read(), incompressibleTwoPhaseMixture::read(), optimisationManager::read(), kinematicSingleLayer::read(), tolerances::read(), thermo::readControls(), adjointSolverManager::readDict(), refinementSurfaces::refinementSurfaces(), rigidBodyMeshMotion::rigidBodyMeshMotion(), rigidBodyMeshMotionSolver::rigidBodyMeshMotionSolver(), rigidBodyModel::rigidBodyModel(), searchableSurfaces::searchableSurfaces(), set(), runTimeCondition::setConditionDict(), subModelBase::setModelProperty(), properties::setObjectProperty(), properties::setObjectResult(), displacementLayeredMotionMotionSolver::solve(), meshState::solverPerformanceDict(), meshState::solverPerformanceDict(), cloudSolution::sourceTermDict(), steadyOptimisation::steadyOptimisation(), thermalBaffle::thermalBaffle(), thermalShell::thermalShell(), thermoSingleLayer::thermoSingleLayer(), topODesignVariables::topODesignVariables(), twoPhaseSystem::twoPhaseSystem(), inverseDistance::update(), vibrationShellModel::vibrationShellModel(), volBSplinesBase::volBSplinesBase(), wideBandAbsorptionEmission::wideBandAbsorptionEmission(), write(), properties::writeAllResultEntries(), and properties::writeResultEntries().

| Foam::dictionary & subDict | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) |
Find and return a sub-dictionary for manipulation.
Fatal if the entry does not exist or is not a sub-dictionary.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 460 of file dictionary.C.
References dictionary::Searcher< Const >::dict(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, dictionary::Searcher< Const >::good(), Foam::nl, relativeName(), and Foam::search().

| Foam::dictionary & subDictOrAdd | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) |
Find and return a sub-dictionary for manipulation.
Fatal if the entry exist and is not a sub-dictionary.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 480 of file dictionary.C.
References dictionary(), dictionary, dictionary::Searcher< Const >::dictPtr(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, dictionary::Searcher< Const >::good(), Foam::nl, relativeName(), Foam::search(), and set().
Referenced by meshState::meshState(), sensitivitySurface::smoothSensitivities(), caseInfo::write(), caseInfo::writeFileDicts(), and caseInfo::writeRegisteredDicts().


| Foam::dictionary subOrEmptyDict | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX, | ||
| const bool | mandatory = false ) const |
Find and return a sub-dictionary as a copy, otherwise return an empty dictionary.
Warn if the entry exists but is not a sub-dictionary.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
| mandatory | the keyword is mandatory (default: false) |
Definition at line 520 of file dictionary.C.
References csearch(), dictionary(), dictionary, dictionary::Searcher< Const >::dictPtr(), Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, dictionary::Searcher< Const >::good(), IOWarningInFunction, Foam::nl, and relativeName().
Referenced by adjointRASModel::adjointRASModel(), coordSetWriter::coordSetWriter(), subModelBase::getModelDict(), incompressiblePrimalSolver::incompressiblePrimalSolver(), optimisationManager::optimisationManager(), radiationModel::radiationModel(), radiationModel::radiationModel(), radiationModel::read(), solverControl::read(), regionFaModel::regionFaModel(), regionModel::regionModel(), regionModel::regionModel(), and surfaceWriter::surfaceWriter().


| const Foam::dictionary & optionalSubDict | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a sub-dictionary, otherwise return this dictionary.
Warn if the entry exists but is not a sub-dictionary.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 559 of file dictionary.C.
References csearch(), dictionary(), dictionary::Searcher< Const >::dictPtr(), Foam::endl(), dictionary::Searcher< Const >::good(), IOWarningInFunction, and relativeName().
Referenced by geometric::add(), combustionModel::combustionModel(), dynamicInkJetFvMesh::dynamicInkJetFvMesh(), linearValveFvMesh::linearValveFvMesh(), linearValveLayersFvMesh::linearValveLayersFvMesh(), displacementMeshMoverMotionSolver::meshMover(), mixerFvMesh::mixerFvMesh(), motionSolver::motionSolver(), movingConeTopoFvMesh::movingConeTopoFvMesh(), anisotropicFilter::read(), combustionModel::read(), laplaceFilter::read(), motionSolver::read(), SRFModel::read(), Arrhenius< ViscousModel >::read(), dynamicRefineFvMesh::readDict(), displacementMeshMoverMotionSolver::solve(), SRFModel::SRFModel(), and dynamicRefineFvMesh::updateTopology().


| Foam::wordList toc | ( | ) | const |
Return the table of contents.
Definition at line 587 of file dictionary.C.
References e, entry, n, and DLListBase::size().
Referenced by adjointSolverManager::adjointSolverManager(), DAC< CompType, ThermoType >::DAC(), removeEntry::execute(), FreeStream< CloudType >::FreeStream(), optimisationManager::initialize(), oversetFvMeshBase::interpolateFields(), adjointSolverManager::nActiveAdjointSolvers(), objectiveManager::objectiveManager(), pyrolysisModelCollection::pyrolysisModelCollection(), cloudSolution::read(), runTimeControl::read(), multiphaseMangrovesSource::read(), multiphaseMangrovesTurbulenceModel::read(), and refinementSurfaces::refinementSurfaces().


| Foam::wordList sortedToc | ( | ) | const |
Return the sorted table of contents.
Definition at line 601 of file dictionary.C.
Referenced by equationInitialResidualCondition::apply(), objectiveFlowRate::objectiveFlowRate(), objectiveFlowRatePartition::objectiveFlowRatePartition(), objectiveForce::objectiveForce(), objectiveMoment::objectiveMoment(), objectivePartialVolume::objectivePartialVolume(), properties::objectNames(), sortedToc(), solverFieldSelection::updateSelection(), caseInfo::write(), properties::writeAllResultEntries(), and properties::writeResultEntries().

| wordList sortedToc | ( | const Compare & | comp | ) | const |
Return table of contents sorted using the specified comparator.
References add(), dictionary(), e, entry, k, keys(), sortedToc(), substituteKeyword(), substituteScopedKeyword(), and Foam::T().

| Foam::List< Foam::keyType > keys | ( | bool | patterns = false | ) | const |
Return the list of available keys or patterns.
Definition at line 607 of file dictionary.C.
References e, entry, n, List< T >::resize(), and DLListBase::size().
Referenced by sortedToc().


| bool substituteKeyword | ( | const word & | keyword, |
| bool | mergeEntry = false ) |
Substitute the given keyword (which is prefixed by '$').
with the corresponding sub-dictionary entries
Definition at line 376 of file dictionary.C.
References Foam::add(), csearch(), dictionary::Searcher< Const >::dict(), e, entry, dictionary::Searcher< Const >::good(), and keyType::REGEX_RECURSIVE.
Referenced by sortedToc().


| bool substituteScopedKeyword | ( | const word & | keyword, |
| bool | mergeEntry = false ) |
Substitute the given scoped keyword (which is prefixed by '$').
with the corresponding sub-dictionary entries
Definition at line 408 of file dictionary.C.
References Foam::add(), csearchScoped(), e, entry, and keyType::REGEX_RECURSIVE.
Referenced by entry::New(), and sortedToc().


| Foam::entry * add | ( | entry * | entryPtr, |
| bool | mergeEntry = false ) |
Add a new entry.
| entryPtr | the entry to add |
| mergeEntry | dictionaries are interwoven and primitive entries are overwritten (default: false) |
Definition at line 625 of file dictionary.C.
References fileName::concat(), entry::dict(), Foam::endl(), entry, IOWarningInFunction, isDict(), entry::isDict(), keyType::isPattern(), entry::keyword(), entry::name(), name, autoPtr< T >::New(), DLListBase::push_back(), relativeName(), UILList< DLListBase, T >::remove(), and DLListBase::replace().
Referenced by add(), snappyLayerDriver::addLayers(), Foam::addPatchTypeDetails(), adjointSimple::addTopOFvOptions(), adjointSolverManager::adjointSolverManager(), snappyLayerDriver::determineSidePatches(), faPatchData::dict(), Foam::dimensionedConstant(), refinementParameters::getZoneInfo(), optimisationManager::initialize(), voxelMeshSearch::makeMesh(), makeScopedDict(), namedBlock::namedBlock(), namedVertex::namedVertex(), entry::New(), Foam::preservePatchTypes(), multiRegion::read(), functionObjectList::readFunctionObject(), subModelBase::setBaseProperty(), runTimeCondition::setConditionDict(), subModelBase::setModelProperty(), properties::setObjectProperty(), properties::setObjectResult(), sensitivitySurface::smoothSensitivities(), rigidBodyMeshMotion::solve(), rigidBodyMeshMotionSolver::solve(), sixDoFRigidBodyMotionSolver::solve(), sortedToc(), kinematicSingleLayer::transferPrimaryRegionSourceFields(), sixDoFRigidBodyDisplacementPointPatchVectorField::updateCoeffs(), solution::upgradeSolverDict(), thermoCoupleProbes::write(), surfaceFeatures::writeDict(), caseInfo::writeFunctionObjects(), caseInfo::writeMeta(), caseInfo::writePatches(), valueAverageBase::writeState(), abaqusWriter::writeTemplate(), and Time::writeTimeDict().


| Foam::entry * add | ( | const entry & | e, |
| bool | mergeEntry = false ) |
Add an entry.
| e | the entry to add |
| mergeEntry | dictionaries are interwoven and primitive entries are overwritten (default: false) |
Definition at line 704 of file dictionary.C.
References Foam::add(), e, and entry.

| Foam::entry * add | ( | const keyType & | k, |
| const word & | v, | ||
| bool | overwrite = false ) |
Add a word entry.
| overwrite | force overwrite of an existing entry. |
Definition at line 710 of file dictionary.C.
References Foam::add(), and k.

| Foam::entry * add | ( | const keyType & | k, |
| const string & | v, | ||
| bool | overwrite = false ) |
Add a string entry.
| overwrite | force overwrite of an existing entry. |
Definition at line 721 of file dictionary.C.
References Foam::add(), and k.

| Foam::entry * add | ( | const keyType & | k, |
| const label | v, | ||
| bool | overwrite = false ) |
Add a label entry.
| overwrite | force overwrite of an existing entry. |
Definition at line 732 of file dictionary.C.
References Foam::add(), and k.

| Foam::entry * add | ( | const keyType & | k, |
| const scalar | v, | ||
| bool | overwrite = false ) |
Add a scalar entry.
| overwrite | force overwrite of an existing entry. |
Definition at line 743 of file dictionary.C.
References Foam::add(), and k.

| Foam::entry * add | ( | const keyType & | k, |
| const dictionary & | d, | ||
| bool | mergeEntry = false ) |
Add a dictionary entry.
| mergeEntry | merge into an existing sub-dictionary |
Definition at line 754 of file dictionary.C.
References Foam::add(), dictionary(), and k.

| Foam::entry * set | ( | entry * | entryPtr | ) |
Assign a new entry, overwriting any existing entry.
Definition at line 765 of file dictionary.C.
References Foam::add(), clear(), dictionary(), dictionary::Searcher< Const >::dictPtr(), entry, entry::keyword(), keyType::REGEX, and Foam::search().
Referenced by add(), columnFvMeshInfo::addLocalPatches(), meshRefinement::addPatch(), valueAverageBase::calc(), extrudePatchMesh::extrudePatchMesh(), regionModel::interRegionAMI(), fvMeshTools::newMesh(), operator<<=(), polyMesh::polyMesh(), multiFieldValue::read(), runTimeControl::read(), functionObjectList::readFunctionObject(), codedFunctionObject::redirectFunctionObject(), codedPoints0MotionSolver::redirectMotionSolver(), CodedSource< Type >::redirectOption(), codedFixedValueFvPatchField< Type >::redirectPatchField(), codedFixedValuePointPatchField< Type >::redirectPatchField(), codedMixedFvPatchField< Type >::redirectPatchField(), set(), set(), set(), set(), set(), set(), properties::setTrigger(), subDictOrAdd(), and solution::upgradeSolverDict().


| Foam::entry * set | ( | const entry & | e | ) |
Assign a new entry, overwriting any existing entry.
Definition at line 787 of file dictionary.C.
References e, entry, and set().

| Foam::entry * set | ( | const keyType & | k, |
| const dictionary & | v ) |
Assign a dictionary entry, overwriting any existing entry.
Definition at line 793 of file dictionary.C.
References dictionary(), k, and set().

| Foam::entry * set | ( | const keyType & | k, |
| std::nullptr_t | ) |
Assign an empty primitive entry, overwriting any existing entry.
Definition at line 799 of file dictionary.C.

| Foam::entry * set | ( | const keyType & | k, |
| const UList< token > & | tokens ) |
Assign a primitive entry from a list of tokens, overwriting any existing entry.
Definition at line 805 of file dictionary.C.
References k, set(), and tokens().

| Foam::entry * set | ( | const keyType & | k, |
| List< token > && | tokens ) |
Assign a primitive entry from a list of tokens, overwriting any existing entry.
Definition at line 811 of file dictionary.C.
References k, set(), and tokens().

Assign a T entry, overwriting any existing entry.
References cfindScopedDict(), changeKeyword(), checkITstream(), clear(), csearch(), csearchCompat(), csearchScoped(), dict, dictionary(), dictPath(), entry, findCompat(), findScopedDict(), foundCompat(), getCompat(), getOrDefaultCompat(), k, lookupCompat(), lookupEntryCompat(), makeScopedDict(), merge(), UILList< DLListBase, T >::operator, os(), read(), readCompat(), readIfPresentCompat(), remove(), Foam::rhs(), search(), searchScoped(), set(), subDict(), Foam::T(), transfer(), write(), writeEntries(), and writeEntry().

| bool remove | ( | const word & | keyword | ) |
Remove an entry specified by keyword.
Definition at line 576 of file dictionarySearch.C.
References UILList< DLListBase, T >::remove().
Referenced by properties::clearTrigger(), removeEntry::execute(), read(), set(), caseInfo::writeFileDicts(), and caseInfo::writeRegisteredDicts().


| bool changeKeyword | ( | const keyType & | oldKeyword, |
| const keyType & | newKeyword, | ||
| bool | overwrite = false ) |
Change the keyword for an entry,.
| overwrite | force overwrite of an existing entry. |
Definition at line 604 of file dictionarySearch.C.
References fileName::concat(), Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, IOWarningInFunction, keyType::isPattern(), name, autoPtr< T >::New(), Foam::nl, and DLListBase::replace().
Referenced by CodedSource< Type >::redirectOption(), and set().


| bool merge | ( | const dictionary & | dict | ) |
Merge entries from the given dictionary.
Also merge sub-dictionaries as required.
Definition at line 817 of file dictionary.C.
References Foam::abort(), Foam::add(), dict, dictionary(), e, entry, Foam::FatalIOError, FatalIOErrorInFunction, isDict(), merge(), Foam::nl, and relativeName().
Referenced by snappyLayerDriver::addLayers(), Foam::combineFormatOptions(), merge(), Time::readDict(), waveModel::readDict(), functionObjectList::readFunctionObject(), and set().


| void clear | ( | ) |
Clear the dictionary.
Definition at line 862 of file dictionary.C.
References ILList< DLListBase, T >::clear().
Referenced by writerCaching::clear(), set(), set(), Time::setMonitoring(), and caseInfo::write().


| void transfer | ( | dictionary & | dict | ) |
Transfer the contents of the argument and annul the argument.
Definition at line 871 of file dictionary.C.
References dict, dictionary(), name, and ILList< DLListBase, T >::transfer().
Referenced by dictionary(), dictionary(), and set().


Check after reading if the input token stream has unconsumed tokens remaining or if there were no tokens in the first place.
Emits FatalIOError
Definition at line 250 of file dictionary.C.
References JobInfo::constructed, Foam::exit(), Foam::FatalIOError, IOstream::lineNumber(), Foam::nl, ITstream::nRemainingTokens(), relativeName(), UList< T >::size(), and UList< T >::writeList().
Referenced by getCheckOrAdd(), getCheckOrDefault(), getOrAdd(), getOrDefault(), getOrDefaultCompat(), readCheck(), readCompat(), readEntry(), and set().


| bool read | ( | Istream & | is | ) |
Read dictionary from Istream (discards the header). Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character.
Definition at line 134 of file dictionaryIO.C.
References Foam::read().
Referenced by atmPlantCanopyTurbSource::atmPlantCanopyTurbSource(), dictionary(), dictionary(), calcEntry::execute(), codeStream::execute(), includeEntry::execute(), includeEtcEntry::execute(), Foam::operator>>(), IOobject::readHeader(), and set().


| bool read | ( | Istream & | is, |
| bool | keepHeader ) |
Read dictionary from Istream (optionally keeping the header) Reads entries until EOF or when the first token is a '{' character, it will stop reading at the matching '}' character.
Definition at line 70 of file dictionaryIO.C.
References IOstream::bad(), token::BEGIN_BLOCK, token::END_BLOCK, Foam::endl(), IOstream::eof(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, entry::GLOBAL, IOstream::good(), InfoInFunction, name, entry::New(), Foam::nl, Istream::putBack(), and remove().

| void writeEntry | ( | Ostream & | os | ) | const |
Write sub-dictionary with its dictName as its header.
Definition at line 157 of file dictionaryIO.C.
References dictName(), os(), and writeEntries().
Referenced by Foam::operator<<(), set(), sensitivitySurface::smoothSensitivities(), dictionaryEntry::write(), quasiNewton::writeData(), Foam::writeEntryIfPresent(), and IOobject::writeHeaderContent().


Write sub-dictionary with the keyword as its header.
Definition at line 165 of file dictionaryIO.C.
References os(), and writeEntries().

| void writeEntries | ( | Ostream & | os, |
| const bool | extraNewLine = false ) const |
Write dictionary entries.
| extraNewLine | adds additional newline between entries for "top-level" dictionaries |
Definition at line 173 of file dictionaryIO.C.
References e, Foam::endl(), entry, name, Foam::nl, null, os(), parent(), and WarningInFunction.
Referenced by set(), write(), writeEntry(), writeEntry(), and decomposedBlockData::writeHeader().


| void write | ( | Ostream & | os, |
| const bool | subDict = true ) const |
Write dictionary, normally with sub-dictionary formatting.
Definition at line 204 of file dictionaryIO.C.
References Foam::nl, os(), subDict(), and writeEntries().
Referenced by set(), dictionaryListEntry::write(), baseIOdictionary::writeData(), fieldDictionary::writeData(), and surfaceFeatures::writeDict().


| Foam::dictionary::const_searcher csearch | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Search dictionary for given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 256 of file dictionarySearch.C.
References null, keyType::RECURSIVE, keyType::REGEX, and dictionary::Searcher< Const >::set().
Referenced by csearchCompat(), findDict(), findDict(), findEntry(), findEntry(), findStream(), getCheckOrAdd(), getCheckOrDefault(), getOrAdd(), getOrDefault(), optionalSubDict(), readCheck(), readEntry(), search(), search(), set(), subDict(), subOrEmptyDict(), and substituteKeyword().


| Foam::dictionary::const_searcher search | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Search dictionary for given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 294 of file dictionarySearch.C.
References csearch().
Referenced by entry::New(), and set().


| Foam::dictionary::searcher search | ( | const word & | keyword, |
| enum keyType::option | matchOpt = keyType::REGEX ) |
Search dictionary for given keyword.
| keyword | the keyword to search for |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 304 of file dictionarySearch.C.
References csearch().

| Foam::dictionary::const_searcher csearchScoped | ( | const word & | keyword, |
| enum keyType::option | matchOpt ) const |
Search using scoping.
There are two types of scoping available:
For dot-scoping, a leading '^' traverses to the top-level dictionary, leading dots mean use the parent dictionary and an intermediate dot separates a sub-dictionary or sub-entry. However, since the use of dots is ambiguous ("a.b.c" could be an entry itself or represent a "bc" entry from dictionary "a" etc), the heuristic backtracks and attempts successively longer top-level entries until a suitable match is found.
For slash-scoping, semantics similar to directory structures are used. A leading '/' traverses to the top-level dictionary, a single leading or intermediate '.' references the current dictionary level. A '..' pair references the parent dictionary. Any doubled slashes are silently ignored. Since a slash is not a valid keyword character, there is no ambiguity between separator and content.
| keyword | the keyword to search for |
| matchOpt | search mode |
Definition at line 316 of file dictionarySearch.C.
References string::contains(), dictionary(), null, and keyType::RECURSIVE.
Referenced by findScoped(), entry::New(), searchScoped(), searchScoped(), set(), and substituteScopedKeyword().


| Foam::dictionary::const_searcher searchScoped | ( | const word & | keyword, |
| enum keyType::option | matchOpt ) const |
Search using dot or slash scoping.
| keyword | the keyword to search for |
| matchOpt | search mode |
Definition at line 346 of file dictionarySearch.C.
References csearchScoped().
Referenced by removeEntry::execute(), entry::New(), and set().


| Foam::dictionary::searcher searchScoped | ( | const word & | keyword, |
| enum keyType::option | matchOpt ) |
Search using dot or slash scoping.
| keyword | the keyword to search for |
| matchOpt | search mode |
Definition at line 356 of file dictionarySearch.C.
References csearchScoped().

| const Foam::dictionary * cfindScopedDict | ( | const fileName & | dictPath | ) | const |
Locate a sub-dictionary using slash-scoping.
Definition at line 368 of file dictionarySearch.C.
References dictionary(), dictPath(), entry::dictPtr(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, entry::isDict(), Foam::nl, null, path(), and Foam::stringOps::split().
Referenced by findScopedDict(), findScopedDict(), and set().


| const Foam::dictionary * findScopedDict | ( | const fileName & | dictPath | ) | const |
Locate a sub-dictionary using slash-scoping.
Definition at line 457 of file dictionarySearch.C.
References cfindScopedDict(), and dictPath().
Referenced by set().


| Foam::dictionary * findScopedDict | ( | const fileName & | dictPath | ) |
Locate a sub-dictionary using slash-scoping.
Definition at line 466 of file dictionarySearch.C.
References cfindScopedDict(), dictionary(), and dictPath().

| Foam::dictionary * makeScopedDict | ( | const fileName & | dictPath | ) |
Locate existing or create sub-dictionary using slash-scoping.
Definition at line 476 of file dictionarySearch.C.
References add(), fileName::clean(), dictionary(), dictionary, dictPath(), entry::dictPtr(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, entry::isDict(), Foam::nl, null, path(), and Foam::stringOps::split().
Referenced by entry::New(), and set().


| Foam::dictionary::const_searcher csearchCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Search dictionary for given keyword and any compatibility names.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. Old version 1600=OpenFOAM-v3.0, 240=OpenFOAM-2.4.x, 170=OpenFOAM-1.7.x,... |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 26 of file dictionaryCompat.C.
References csearch(), dictionary::Searcher< Const >::good(), error::master(), Foam::nl, relativeName(), word::validate(), and error::warnAboutAge().
Referenced by findCompat(), getOrDefaultCompat(), readCompat(), and set().


| const Foam::entry * findCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt ) const |
Find and return an entry pointer if present, or return a nullptr, using any compatibility names if needed.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| matchOpt | search mode |
Definition at line 67 of file dictionaryCompat.C.
References csearchCompat().
Referenced by foundCompat(), lookupEntryCompat(), and set().


| bool foundCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Search dictionary for given keyword and any compatibility names.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 78 of file dictionaryCompat.C.
References findCompat().
Referenced by set().


| const Foam::entry & lookupEntryCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt ) const |
Find and return an entry if present, otherwise FatalIOError, using any compatibility names if needed.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| matchOpt | search mode |
Definition at line 89 of file dictionaryCompat.C.
References entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, findCompat(), and relativeName().
Referenced by lookupCompat(), and set().


| Foam::ITstream & lookupCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return an entry data stream, using any compatibility names if needed.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 110 of file dictionaryCompat.C.
References lookupEntryCompat().
Referenced by set().


| T getCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T using any compatibility names if needed. FatalIOError if not found, or if there are excess tokens.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 126 of file dictionaryTemplates.C.
References readCompat(), and Foam::T().
Referenced by codedPoints0MotionSolver::codedPoints0MotionSolver(), basicChemistryModel::New(), motionSolver::New(), plane::plane(), and set().


| T getOrDefaultCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| const T & | deflt, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find and return a T, or return the given default value using any compatibility names if needed.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| deflt | the default value to use |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 452 of file dictionaryTemplates.C.
References checkITstream(), csearchCompat(), entry, entry::stream(), Foam::T(), and writeOptionalEntries.
Referenced by fvDOM::fvDOM(), fvDOM::fvDOM(), NURBS3DVolume::NURBS3DVolume(), objective::objective(), set(), thermalShellModel::thermalShellModel(), and topODesignVariables::topODesignVariables().


| bool readCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| T & | val, | ||
| enum keyType::option | matchOpt = keyType::REGEX, | ||
| IOobjectOption::readOption | readOpt = IOobjectOption::MUST_READ ) const |
Find entry and assign to T val using any compatibility names if needed. FatalIOError if there are excess tokens.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| val | the value to read |
| matchOpt | search mode (default: non-recursive with patterns) |
| readOpt | the entry is required/optional (default: MUST_READ) |
Definition at line 374 of file dictionaryTemplates.C.
References checkITstream(), csearchCompat(), entry, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, IOobjectOption::isReadRequired(), name, Foam::nl, IOobjectOption::NO_READ, entry::stream(), and Foam::T().
Referenced by getCompat(), RASModelVariables::New(), readIfPresentCompat(), and set().


| bool readIfPresentCompat | ( | const word & | keyword, |
| std::initializer_list< std::pair< const char *, int > > | compat, | ||
| T & | val, | ||
| enum keyType::option | matchOpt = keyType::REGEX ) const |
Find an entry if present, and assign to T val using any compatibility names if needed. FatalIOError if it is found and there are excess tokens.
| keyword | the keyword to search for |
| compat | list of old compatibility keywords and the last OpenFOAM version for which they were used. |
| val | the value to read |
| matchOpt | search mode (default: non-recursive with patterns) |
Definition at line 483 of file dictionaryTemplates.C.
References IOobjectOption::READ_IF_PRESENT, readCompat(), and Foam::T().
Referenced by set().


| void operator= | ( | const dictionary & | rhs | ) |
Copy assignment.
Definition at line 886 of file dictionary.C.
References Foam::add(), clear(), dictionary(), e, entry, name, and Foam::rhs().
Referenced by dictionary(), IOdictionary::IOdictionary(), localIOdictionary::localIOdictionary(), baseIOdictionary::operator=(), baseIOdictionary::operator=(), meshState::reset(), and unwatchedIOdictionary::unwatchedIOdictionary().


| void operator+= | ( | const dictionary & | rhs | ) |
Include entries from the given dictionary.
Warn, but do not overwrite existing entries.
Definition at line 906 of file dictionary.C.
References Foam::abort(), Foam::add(), dictionary(), e, entry, Foam::FatalIOError, FatalIOErrorInFunction, Foam::nl, relativeName(), and Foam::rhs().

| void operator|= | ( | const dictionary & | rhs | ) |
Conditionally include entries from the given dictionary.
Do not overwrite existing entries.
Definition at line 923 of file dictionary.C.
References Foam::abort(), Foam::add(), dictionary(), e, entry, Foam::FatalIOError, FatalIOErrorInFunction, found, Foam::nl, relativeName(), and Foam::rhs().

| void operator<<= | ( | const dictionary & | rhs | ) |
Unconditionally include entries from the given dictionary.
Overwrite existing entries.
Definition at line 943 of file dictionary.C.
References Foam::abort(), dictionary(), e, entry, Foam::FatalIOError, FatalIOErrorInFunction, Foam::nl, relativeName(), Foam::rhs(), and set().

|
inline |
Same as get<bool>(const word&, keyType::option).
Definition at line 1701 of file dictionary.H.
References getBool().
Referenced by getBool(), and singleStepCombustion< ReactionThermo, ThermoType >::singleStepCombustion().


|
inline |
Same as get<label>(const word&, keyType::option).
Definition at line 1702 of file dictionary.H.
References getLabel().
Referenced by KirchhoffShell::evolveRegion(), getLabel(), and propellerInfo::setSampleDiskSurface().


|
inline |
Same as get<scalar>(const word&, keyType::option).
Definition at line 1703 of file dictionary.H.
References getScalar().
Referenced by diffusion< ReactionThermo, ThermoType >::diffusion(), eddyDissipationDiffusionModel< ReactionThermo, ThermoType >::eddyDissipationDiffusionModel(), eddyDissipationModelBase< ReactionThermo, ThermoType >::eddyDissipationModelBase(), FSD< ReactionThermo, ThermoType >::FSD(), getScalar(), infinitelyFastChemistry< ReactionThermo, ThermoType >::infinitelyFastChemistry(), PaSR< ReactionThermo >::PaSR(), propellerInfo::setSampleDiskSurface(), and WallSpringSliderDashpot< CloudType >::WallSpringSliderDashpot().


|
inline |
Same as get<string>(const word&, keyType::option).
Definition at line 1704 of file dictionary.H.
References getString().
Referenced by getString().


|
inline |
Same as get<word>(const word&, keyType::option).
Definition at line 1705 of file dictionary.H.
References getWord().
Referenced by getWord(), incompressibleInterPhaseTransportModel< Mixture >::incompressibleInterPhaseTransportModel(), and ParticleZoneInfo< CloudType >::ParticleZoneInfo().


|
inline |
Same as get<fileName>(const word&, keyType::option).
Definition at line 1706 of file dictionary.H.
References getFileName().
Referenced by getFileName().


|
inline |
Check for existence of a sub-dictionary. Generally prefer findDict() for more flexibility.
Definition at line 1718 of file dictionary.H.
References findDict(), and isDict().
Referenced by add(), isDict(), and merge().


|
inline |
Same as getOrDefault().
Definition at line 1732 of file dictionary.H.
References getOrDefault(), lookupOrDefault(), and Foam::T().
Referenced by lookupOrDefault(), and lookupOrDefault().


|
inline |
Same as getOrAdd().
Definition at line 1747 of file dictionary.H.
References getOrAdd(), lookupOrAddDefault(), and Foam::T().
Referenced by lookupOrAddDefault(), and lookupOrAddDefault().


Deprecated(2018-07) - use lookup() method.
Definition at line 1763 of file dictionary.H.
References lookup(), and UILList< DLListBase, T >::operator.

|
inline |
Deprecated(2018-10).
Definition at line 1774 of file dictionary.H.
References found(), and found.

Deprecated(2018-10).
Definition at line 1790 of file dictionary.H.
References entry, findEntry(), and lookupEntryPtr().
Referenced by lookupEntryPtr(), and lookupEntryPtr().


|
inline |
Deprecated(2018-10).
Definition at line 1806 of file dictionary.H.
References entry, findEntry(), and lookupEntryPtr().

|
inline |
Deprecated(2018-10).
Definition at line 1822 of file dictionary.H.
References entry, findScoped(), and lookupScopedEntryPtr().
Referenced by lookupScopedEntryPtr().


|
inline |
Deprecated(2018-10).
Find and return a sub-dictionary pointer if present (and a sub-dictionary) otherwise return nullptr.
Search type: non-recursive with patterns.
Definition at line 1842 of file dictionary.H.
References dictionary(), findDict(), keyType::REGEX, and subDictPtr().
Referenced by basicChemistryModel::New(), subDictPtr(), and subDictPtr().


|
inline |
Deprecated(2018-10) Find and return a sub-dictionary pointer if present.
(and a sub-dictionary) otherwise return nullptr.
Search type: non-recursive with patterns.
Definition at line 1857 of file dictionary.H.
References dictionary(), findDict(), keyType::REGEX, and subDictPtr().

Deprecated(2018-10).
Definition at line 1868 of file dictionary.H.
References entry, and lookupEntry().

Deprecated(2018-10).
Definition at line 1884 of file dictionary.H.
References lookup().

|
inline |
Deprecated(2018-10).
Definition at line 1901 of file dictionary.H.
References getOrDefault(), lookupOrDefault(), and Foam::T().

|
inline |
Deprecated(2018-10).
Definition at line 1919 of file dictionary.H.
References getOrAdd(), lookupOrAddDefault(), and Foam::T().

|
inline |
Deprecated(2018-10).
Definition at line 1937 of file dictionary.H.
References readIfPresent(), and Foam::T().

|
inline |
Deprecated(2018-10) find and return a T.
Definition at line 1960 of file dictionary.H.
References get(), lookupType(), and Foam::T().
Referenced by lookupType().


| Foam::wordList sortedToc | ( | const Compare & | comp | ) | const |
Definition at line 78 of file dictionaryTemplates.C.
| Foam::entry * add | ( | const keyType & | k, |
| const T & | v, | ||
| bool | overwrite ) |
Definition at line 85 of file dictionaryTemplates.C.
References Foam::add(), k, and Foam::T().

| Foam::entry * set | ( | const keyType & | k, |
| const T & | v ) |
Definition at line 92 of file dictionaryTemplates.C.
References k, set(), and Foam::T().

|
friend |
Declare friendship with the entry class for IO.
Definition at line 338 of file dictionary.H.
References entry.
Referenced by add(), add(), add(), cfindScopedDict(), dictionary(), dictionary(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), dictionaryEntry::dictionaryEntry(), digest(), entry, findEntry(), getCheckOrAdd(), getCheckOrDefault(), doxygenXmlParser::getEntry(), getOrAdd(), getOrDefault(), getOrDefaultCompat(), doxygenXmlParser::getValue(), properties::hasResultObjectEntry(), keys(), lookupEntry(), lookupEntry(), lookupEntryCompat(), lookupEntryPtr(), lookupEntryPtr(), lookupScopedEntryPtr(), makeScopedDict(), merge(), properties::objectResultEntries(), properties::objectResultType(), operator+=(), operator<<=(), operator=(), operator|=(), readCheck(), readCompat(), readEntry(), set(), set(), set(), sortedToc(), substituteKeyword(), substituteScopedKeyword(), toc(), tokens(), and writeEntries().
|
friend |
Read dictionary from Istream.
References dict, dictionary(), and UILList< DLListBase, T >::operator.
|
friend |
Write dictionary to Ostream.
References dict, dictionary(), UILList< DLListBase, T >::operator, and os().
| friend const_searcher |
Declare friendship with the searcher classes.
Definition at line 343 of file dictionary.H.
| friend searcher |
Definition at line 344 of file dictionary.H.
|
static |
Report optional keywords and values if not present in dictionary.
For value greater than 1: fatal. Set/unset via an InfoSwitch or -info-switch at the command-line
Definition at line 482 of file dictionary.H.
Referenced by getCheckOrAdd(), getCheckOrDefault(), getOrAdd(), getOrDefault(), getOrDefaultCompat(), registerInfoSwitch(), reportOptional(), and reportOptional().
|
static |
An empty dictionary, which is also the parent for all dictionaries.
Definition at line 487 of file dictionary.H.
Referenced by cellModel::cellModel(), cfindScopedDict(), surfaceIntersection::ClassName(), entry::clone(), codedMixedFvPatchField< Type >::codeContext(), codedFunctionObject::codeContext(), Stokes< BasicTurbulenceModel >::coeffDict(), csearch(), csearchScoped(), MeshedSurfaceProxy< Face >::declareMemberFunctionSelectionTable(), fvExprDriver::declareRunTimeSelectionTable(), primitiveEntry::dict(), primitiveEntry::dict(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionary(), dictionaryListEntry::dictionaryListEntry(), Foam::dimensionedConstant(), faMeshDecomposition::faMeshDecomposition(), faMeshDecomposition::faMeshDecomposition(), writerCaching::fieldsDict(), decompositionMethod::findCoeffsDict(), dynamicCodeContext::good(), isNullDict(), liquidFilmBase::liquidFilmBase(), makeScopedDict(), multiphaseInterSystem::multiphaseInterSystem(), entry::New(), functionObjectList::New(), RASModelVariables::New(), lduMatrix::preconditioner::New(), lduMatrix::smoother::New(), NURBS3DVolume::NURBS3DVolume(), objective::objective(), sizeGroup::iNew::operator()(), motionSolver::iNew::operator()(), phase::iNew::operator()(), phaseModel::iNew::operator()(), parseDriver::operator=(), Foam::functionObjects::operator>>(), Foam::operator>>(), Foam::operator>>(), decompositionMethod::optionalRegionDict(), primitiveEntry::primitiveEntry(), rigidBodyMeshMotion::rigidBodyMeshMotion(), simple::simple(), solver::solver(), surfMesh::storeField(), meshRefinement::subDict(), topOVariablesBase::topOVariablesBase(), triSurfaceMeshPointSet::triSurfaceMeshPointSet(), OFstreamCollator::TypeName(), ConstantField< Type >::TypeName(), updateMethod::updateMethod(), volumetricBSplinesDesignVariables::volumetricBSplinesDesignVariables(), edgeMesh::write(), ABAQUSsurfaceFormat< Face >::write(), ABAQUSsurfaceFormat< Face >::write(), AC3DsurfaceFormat< Face >::write(), AC3DsurfaceFormat< Face >::write(), edgeMeshFormat::write(), edgeMeshFormat::write(), FLMAsurfaceFormat< Face >::write(), FLMAsurfaceFormat< Face >::write(), FLMAZsurfaceFormat< Face >::write(), FLMAZsurfaceFormat< Face >::write(), GTSsurfaceFormat< Face >::write(), GTSsurfaceFormat< Face >::write(), NASsurfaceFormat< Face >::write(), NASsurfaceFormat< Face >::write(), OBJedgeFormat::write(), OBJedgeFormat::write(), OBJsurfaceFormat< Face >::write(), OBJsurfaceFormat< Face >::write(), OFFsurfaceFormat< Face >::write(), OFFsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), STARCDedgeFormat::write(), STARCDedgeFormat::write(), STARCDsurfaceFormat< Face >::write(), STARCDsurfaceFormat< Face >::write(), STLsurfaceFormat< Face >::write(), STLsurfaceFormat< Face >::write(), TRIsurfaceFormat< Face >::write(), TRIsurfaceFormat< Face >::write(), VTKedgeFormat::write(), VTKedgeFormat::write(), VTKsurfaceFormat< Face >::write(), VTKsurfaceFormat< Face >::write(), VTPsurfaceFormat< Face >::write(), VTPsurfaceFormat< Face >::write(), X3DsurfaceFormat< Face >::write(), X3DsurfaceFormat< Face >::write(), MeshedSurface< face >::write(), MeshedSurface< face >::write(), MeshedSurface< face >::write(), MeshedSurface< face >::write(), MeshedSurfaceProxy< Face >::write(), MeshedSurfaceProxy< Face >::write(), UnsortedMeshedSurface< face >::write(), UnsortedMeshedSurface< face >::write(), UnsortedMeshedSurface< face >::write(), UnsortedMeshedSurface< face >::write(), writeEntries(), ABAQUSsurfaceFormat< Face >::~ABAQUSsurfaceFormat(), AC3DsurfaceFormat< Face >::~AC3DsurfaceFormat(), edgeMeshFormat::~edgeMeshFormat(), FLMAsurfaceFormat< Face >::~FLMAsurfaceFormat(), FLMAZsurfaceFormat< Face >::~FLMAZsurfaceFormat(), GTSsurfaceFormat< Face >::~GTSsurfaceFormat(), NASsurfaceFormat< Face >::~NASsurfaceFormat(), OBJedgeFormat::~OBJedgeFormat(), OBJsurfaceFormat< Face >::~OBJsurfaceFormat(), OFFsurfaceFormat< Face >::~OFFsurfaceFormat(), SMESHsurfaceFormat< Face >::~SMESHsurfaceFormat(), STARCDedgeFormat::~STARCDedgeFormat(), STARCDsurfaceFormat< Face >::~STARCDsurfaceFormat(), STLsurfaceFormat< Face >::~STLsurfaceFormat(), TRIsurfaceFormat< Face >::~TRIsurfaceFormat(), VTKedgeFormat::~VTKedgeFormat(), VTKsurfaceFormat< Face >::~VTKsurfaceFormat(), VTPsurfaceFormat< Face >::~VTPsurfaceFormat(), and X3DsurfaceFormat< Face >::~X3DsurfaceFormat().
|
static |
Output location when reporting default values.
Definition at line 492 of file dictionary.H.