Go to the documentation of this file.
35 template<
class LListBase,
class T>
44 template<
class LListBase,
class T>
56 is.
fatalCheck(
"LList::readList : reading first token");
60 const label len = tok.labelToken();
67 if (delimiter == token::BEGIN_LIST)
69 for (label i=0; i<len; ++i)
81 for (label i=0; i<len; ++i)
91 else if (tok.isPunctuation(token::BEGIN_LIST))
96 while (!tok.isPunctuation(token::END_LIST))
111 <<
"incorrect first token, expected <int> or '(', found "
121 template<
class LListBase,
class T>
130 const label len = this->size();
134 (len <= 1 || !shortLen)
139 os << len << token::BEGIN_LIST;
143 for (
const T& val : *
this)
145 if (space)
os << token::SPACE;
151 os << token::END_LIST;
156 os <<
nl << len <<
nl << token::BEGIN_LIST <<
nl;
159 for (
const T& val : *
this)
165 os << token::END_LIST;
173 template<
class LListBase,
class T>
176 return list.readList(is);
180 template<
class LListBase,
class T>
183 return list.writeList(
os, -1);
void append(const T &item)
bool isLabel() const noexcept
char readBeginList(const char *funcName)
bool fatalCheck(const char *operation) const
char readEndList(const char *funcName)
Istream & operator>>(Istream &, directionInfo &)
A token holds an item read from Istream.
Template class for non-intrusive linked lists.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
InfoProxy< token > info() const
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
Istream & readList(Istream &is)
bool isPunctuation() const noexcept
OBJstream os(runTime.globalPath()/outputName)
errorManipArg< error, int > exit(error &err, const int errNo=1)
void putBack(const token &tok)
#define FatalIOErrorInFunction(ios)
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Ostream & writeList(Ostream &os, const label shortLen=0) const