Cerata
A library to generate structural hardware designs
|
#include <logging.h>
Public Types | |
using | CallbackSignature = void(LogLevel, const std::string &, char const *, char const *, int) |
Signature of the callback function. | |
Public Member Functions | |
void | enable (std::function< CallbackSignature > callback) |
Enable the logger. Can only be done after the callback function was set. | |
bool | IsEnabled () |
Return true if callback was set, false otherwise. | |
void | write (LogLevel level, std::string const &message, char const *source_function, char const *source_file, int line_number) |
Write something using the logging callback function. | |