45 maxErrors_(maxErrors),
52 const char* functionName,
53 const char* sourceFileName,
54 const int sourceFileLineNumber
60 <<
" From function " << functionName <<
endl 61 <<
" in file " << sourceFileName
62 <<
" at line " << sourceFileLineNumber <<
endl 71 const string& functionName,
72 const char* sourceFileName,
73 const int sourceFileLineNumber
87 const char* functionName,
88 const char* sourceFileName,
89 const int sourceFileLineNumber,
90 const string& ioFileName,
91 const label ioStartLineNumber,
92 const label ioEndLineNumber
98 <<
" From function " << functionName <<
endl 99 <<
" in file " << sourceFileName
100 <<
" at line " << sourceFileLineNumber <<
endl 101 <<
" Reading " << ioFileName;
103 if (ioStartLineNumber >= 0 && ioEndLineNumber >= 0)
105 os <<
" from line " << ioStartLineNumber
106 <<
" to line " << ioEndLineNumber;
108 else if (ioStartLineNumber >= 0)
110 os <<
" at line " << ioStartLineNumber;
121 const char* functionName,
122 const char* sourceFileName,
123 const int sourceFileLineNumber,
131 sourceFileLineNumber,
133 ioStream.lineNumber(),
141 const char* functionName,
142 const char* sourceFileName,
143 const int sourceFileLineNumber,
151 sourceFileLineNumber,
153 dict.startLineNumber(),
161 if (communicator != -1)
165 Pout<<
"** messageStream with comm:" << communicator
187 if (!master && collect)
195 os <<
title().c_str();
222 "--> FOAM Serious Error : ",
229 "--> FOAM Warning : ",
235 bool Foam::writeInfoHeader =
true;
static void printStack(Ostream &)
Helper function to print a stack.
errorSeverity
Severity flags.
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const string & title() const
Return the title of this error type.
Ostream & endl(Ostream &os)
Add newline and flush stream.
static bool master(const label communicator=0)
Am I the master process.
Class to handle messaging in a simple, consistent stream-based manner.
static label worldComm
Default communicator (all processors)
OSstream & operator()(const char *functionName, const char *sourceFileName, const int sourceFileLineNumber=0)
Convert to OSstream.
messageStream(const string &title, const errorSeverity, const int maxErrors=0)
Construct from components.
OFstream Snull
Global predefined null output stream "/dev/null".
messageStream SeriousError
int debugSwitch(const char *name, const int defaultValue=0)
Lookup debug switch or add default value.
OSstream Sout(cout, "Sout")
static label warnComm
Debugging: warn for use of any communicator differing from warnComm.
errorManip< error > abort(error &err)
static bool & parRun()
Is this a parallel run?
An IOstream is an abstract base class for all input/output systems; be they streams, files, token lists etc.
prefixOSstream Pout(cout, "Pout")