29 #ifndef CASA_LOGMESSAGE_H
30 #define CASA_LOGMESSAGE_H
32 #include <casacore/casa/aips.h>
33 #include <casacore/casa/Logging/LogOrigin.h>
34 #include <casacore/casa/OS/Time.h>
35 #include <casacore/casa/iosfwd.h>
LogMessage & sourceLocation(const SourceLocation *where)
Set the source location - usually this will be called with the macro WHERE.
LogMessage(const LogMessage &other)
Make this LogMessage a copy of other.
LogMessage(const String &message, const LogOrigin &sourceLocation, Priority=NORMAL)
Create a completely filled out LogMessage.
LogMessage & line(uInt which)
const LogOrigin & origin() const
Get and set the origin of this LogMessage.
static const String & toString(Priority which)
Map the given priority into a String - so, for example, it can be stored in a table.
String toString() const
Turn this entire LogMessage into a String.
const Time & messageTime() const
Returns the time at which the message text was created.
LogMessage & origin(const LogOrigin &origin)
LogMessage & message(const String &message, Bool keepLastTime=False)
Set the message text.
LogMessage & operator=(const LogMessage &other)
Priority
An "importance" which is assigned to each LogMessage.
@ WARN
Use messages of warning level to flag things that are unusual and might well be errors.
@ DEBUGGING
Low priority - primarily used for findding problems or tracing execution.
@ NORMAL5
Most messages users see should have this priority.
@ SEVERE
Report on a problem detected by the software.
uInt line() const
Get and set the line number in the LogOrigin.
String toTermString() const
LogMessage(Priority priority=NORMAL)
Create a message with the given priority and the current time, and an empty origin and message.
void copy_other(const LogMessage &other)
Provide common implementation for copy constructor and assignment operator.
const String & message() const
Get the message text.
LogMessage & messageTime(const Time &theTime)
Normally you should not manually set the time, however there may be rare circumstances where it is us...
LogMessage & priority(Priority which)
LogMessage(const LogOrigin &sourceLocation, Priority priority=NORMAL)
Create a message with the given location and priority, the current time and an empty message.
Priority priority() const
Get or change the priority of this LogMessage.
String: the storage and methods of handling collections of characters.
this file contains all the compiler specific defines
bool Bool
Define the standard types used by Casacore.
ostream & operator<<(ostream &os, const IComplex &)
Show on ostream.