FERS 1.0.0
The Flexible Extensible Radar Simulator
Loading...
Searching...
No Matches
logging.h File Reference

Header file for the logging system. More...

#include <expected>
#include <format>
#include <fstream>
#include <mutex>
#include <source_location>
#include <string>
#include <utility>
+ Include dependency graph for logging.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  logging::Logger
 Thread-safe logger class for handling logging operations. More...
 

Namespaces

namespace  logging
 

Macros

#define LOG(level, ...)   log(level, std::source_location::current(), __VA_ARGS__)
 

Enumerations

enum class  logging::Level {
  logging::TRACE , logging::DEBUG , logging::INFO , logging::WARNING ,
  logging::ERROR , logging::FATAL
}
 

Functions

std::string logging::getLevelString (const Level level) noexcept
 Converts a log level enum value to its string representation.
 
template<typename... Args>
void logging::log (Level level, const std::source_location &location, const std::string &formatStr, Args &&... args) noexcept
 Logs a formatted message with a specific log level and source location.
 

Detailed Description

Header file for the logging system.

This file defines a logging system with multiple log levels, supporting thread-safe logging to a file or standard output, and allowing formatted log messages with source location details. The logging system is customizable with log levels and file output for effective debugging and tracking of events in an application.

Definition in file logging.h.

Macro Definition Documentation

◆ LOG

#define LOG (   level,
  ... 
)    log(level, std::source_location::current(), __VA_ARGS__)

Definition at line 19 of file logging.h.