54 return fatalCheck(operation);
60 const bool ok = !bad();
65 <<
"error in IOstream " << relativeName()
66 <<
" for operation " << operation
76 os <<
"IOstream: " <<
"Version " <<
version() <<
", format " 77 <<
format() <<
", line " << lineNumber();
115 if (streamState == std::ios_base::goodbit)
117 os <<
"goodbit set : the last operation on stream succeeded" <<
endl;
119 else if (streamState & std::ios_base::badbit)
121 os <<
"badbit set : characters possibly lost" <<
endl;
123 else if (streamState & std::ios_base::failbit)
125 os <<
"failbit set : some type of formatting error" <<
endl;
127 else if (streamState & std::ios_base::eofbit)
129 os <<
"eofbit set : at end of stream" <<
endl;
140 const InfoProxy<IOstream>& iproxy
fileName relativeName() const
Return the name of the stream relative to the current case.
A class for handling file names.
virtual const fileName & name() const
The name of the stream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
virtual bool check(const char *operation) const
Check IOstream status for given operation.
static fileName staticName_
Name for any generic stream - normally treat as readonly.
Ostream & endl(Ostream &os)
Add newline and flush stream.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
OBJstream os(runTime.globalPath()/outputName)
virtual void print(Ostream &os) const
Print stream description to Ostream.
static fileName envRelativePath(const fileName &input, const bool caseTag=false)
Return the input relative to the globalPath by stripping off a leading value of the envGlobalPath...
word format(conversionProperties.get< word >("format"))
const std::string version
OpenFOAM version (name or stringified number) as a std::string.
bool fatalCheck(const char *operation) const
Check IOstream status for given operation.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
IOerror FatalIOError
Error stream (stdout output on all processes), with additional 'FOAM FATAL IO ERROR' header text and ...