Go to the documentation of this file.
66 std::ostringstream buf;
69 return word(buf.str(),
false);
75 char* endptr =
nullptr;
105 char* endptr =
nullptr;
144 <<
"Bad token - could not get scalar value"
175 <<
"Wrong token type - expected scalar value, found ";
static const Scalar vsmall
pTraits(const Base &obj)
Copy construct from base class.
A class for handling words, derived from Foam::string.
Scalar ScalarRead(const char *buf)
Parse entire buffer as a float/double, skipping leading/trailing whitespace.
errorType checkConversion(const char *buf, char *endptr)
Sanity check after strtof, strtod, etc.
Istream & operator>>(Istream &, directionInfo &)
A token holds an item read from Istream.
virtual Ostream & write(const char c)
Write character.
punctuationToken pToken() const
Return punctuation character.
bool isNumber() const noexcept
Token is LABEL, FLOAT or DOUBLE.
Subtract or start of negative number.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
scalar number() const
Return label, float or double value.
InfoProxy< token > info() const
Return info proxy for printing token information to a stream.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
static const char *const typeName
bool isPunctuation() const noexcept
Token is PUNCTUATION.
static const Scalar rootMax
const Foam::Enum< errorType > errorNames
Strings corresponding to the errorType.
errorType
Enumeration for possible parsing error.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
OBJstream os(runTime.globalPath()/outputName)
errorManipArg< error, int > exit(error &err, const int errNo=1)
bool good() const noexcept
True if token is not UNDEFINED or ERROR.
static const char *const componentNames[]
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
void setBad()
Set stream state to be 'bad'.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
static const Scalar rootMin