Webserv
|
#include <string>
#include <sstream>
Go to the source code of this file.
Classes | |
class | utils::Logger |
Namespaces | |
namespace | utils |
Macros | |
#define | LOG_MSG(level, msg) |
The base macro for logging. It constructs a string from the stream-like input and passes it to the core logging function. | |
#define | LOG_TRACE(msg) |
Logs a message with the TRACE severity level. | |
#define | LOG_DEBUG(msg) |
Logs a message with the DEBUG severity level. | |
#define | LOG_INFO(msg) |
Logs a message with the INFO severity level. | |
#define | LOG_WARN(msg) |
Logs a message with the WARNING severity level. | |
#define | LOG_ERROR(msg) |
Logs a message with the ERROR severity level. | |
#define | LOG_FATAL(msg) |
Logs a message with the FATAL severity level. |
Enumerations | |
enum | utils::LogLevel { utils::TRACE , utils::DEBUG , utils::INFO , utils::WARNING , utils::ERROR , utils::FATAL } |
Defines the severity levels for log messages. More... |
#define LOG_DEBUG | ( | msg | ) |
Logs a message with the DEBUG severity level.
Use for information useful during development and debugging.
#define LOG_ERROR | ( | msg | ) |
Logs a message with the ERROR severity level.
Use for errors that the application can recover from.
#define LOG_FATAL | ( | msg | ) |
Logs a message with the FATAL severity level.
Use for critical errors that prevent the application from continuing.
#define LOG_INFO | ( | msg | ) |
Logs a message with the INFO severity level.
Use for general application progress and lifecycle events.
#define LOG_MSG | ( | level, | |
msg ) |
The base macro for logging. It constructs a string from the stream-like input and passes it to the core logging function.
level | The utils::LogLevel for the message. |
msg | A streamable expression (e.g., "User ID: " << id). |
#define LOG_TRACE | ( | msg | ) |
Logs a message with the TRACE severity level.
Use for highly detailed, step-by-step execution flow.
#define LOG_WARN | ( | msg | ) |
Logs a message with the WARNING severity level.
Use for potential problems that do not stop program execution.