Define the logger class here.
More...
#include <logger.h>
|
| logger_class () |
| Constructor without parameters, set the logger to std::out.
|
|
| logger_class (std::string filename) |
| Construct with filename.
|
|
| logger_class (std::ostream stream) |
| Construct with stream.
|
|
| ~logger_class () |
| Close the file in the destructor.
|
|
void | set_verbosity (int level) |
| Set logging level.
|
|
void | increase_level () |
|
void | decrease_level () |
|
void | set_output (std::ostream stream) |
| Set the output stream.
|
|
void | set_output (std::string filename) |
| Open stream to a file. Interprets strings as filenames.
|
|
template<typename T > |
void | log (T text) |
| Log function.
|
|
Define the logger class here.
Definition at line 8 of file logger.h.
◆ decrease_level()
void logger_class::decrease_level |
( |
| ) |
|
|
inline |
Decrease logging level. Should be called when exiting a specialized area of code.
Definition at line 44 of file logger.h.
◆ increase_level()
void logger_class::increase_level |
( |
| ) |
|
|
inline |
Increase logging level. Should be called when entering a specialized area of code.
Definition at line 40 of file logger.h.
◆ operator<<
Streaming operator for the logger class. Only node 0 prints. This should also accept formatting correctly.
Definition at line 77 of file logger.h.
The documentation for this class was generated from the following file: