Configurable, parallel logging. More...
Classes | |
struct | guard |
Scope guard for categorizing output. More... | |
struct | tag |
A tag for labeling output to enable. More... | |
Macros | |
#define | fixme() |
Alias for severity level warn. | |
#define | flog(severity) |
This handles all of the different logging modes for the insertion style logging interface. | |
#define | flog_assert(test, message) |
Flog assertion interface. | |
#define | flog_error(stream) |
Method style interface for error level severity log entries. | |
#define | flog_fatal(message) |
Throw a runtime exception with the provided message. | |
#define | flog_info(stream) |
Method style interface for info level severity log entries. | |
#define | flog_trace(stream) |
Method style interface for trace level severity log entries. | |
#define | flog_warn(stream) |
Method style interface for warn level severity log entries. | |
Functions | |
void | add_output_stream (std::string const &label, std::ostream &stream, bool colorize=false) |
Add an output stream to FLOG. | |
void | flush () |
Explicitly flush buffered flog output. | |
auto | tags () |
Get all defined tags. | |
Configurable, parallel logging.
If disabled at configuration time, no output is produced.
The name flecsi::log
may also be used, but is deprecated.
#define flog | ( | severity | ) |
This handles all of the different logging modes for the insertion style logging interface.
severity | The severity level of the log entry. |
Usage
#define flog_trace | ( | stream | ) |
Method style interface for trace level severity log entries.
stream | The stream to be printed. |
Usage
#define flog_info | ( | stream | ) |
Method style interface for info level severity log entries.
stream | The stream to be printed. |
Usage
#define flog_warn | ( | stream | ) |
Method style interface for warn level severity log entries.
stream | The stream to be printed. |
Usage
#define flog_error | ( | stream | ) |
Method style interface for error level severity log entries.
stream | The stream to be printed. |
Usage
#define fixme | ( | ) |
Alias for severity level warn.
#define flog_fatal | ( | message | ) |
Throw a runtime exception with the provided message.
If FLECSI_BACKTRACE
is set in the environment and NDEBUG
is not defined, produce a backtrace.
message | The stream message to be printed. |
Usage
#define flog_assert | ( | test, | |
message | |||
) |
Flog assertion interface.
Assertions allow the developer to catch invalid program state. This call will invoke flog_fatal if the test condition is false.
test | The test condition. |
message | The stream message to be printed. |
Usage
void flush | ( | ) |
Explicitly flush buffered flog output.
auto tags | ( | ) |
Get all defined tags.
std::string
objects void add_output_stream | ( | std::string const & | label, |
std::ostream & | stream, | ||
bool | colorize = false |
||
) |
Add an output stream to FLOG.
label | An identifier for the stream. This can be used to access or update an output stream after it has been added. |
stream | The output stream to add. |
colorize | Indicates whether the output to this stream should be colorized. It is useful to turn colorization off for non-interactive output (default). |