JustAnotherDnDGame 0.1.0
Jeu de rôle tactique au d20, vue de dessus, en C++/Qt
Loading...
Searching...
No Matches
LogFormat.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2026 Valentin Eloy
2// SPDX-License-Identifier: GPL-3.0-or-later
3
4#pragma once
5
6#include <string>
7#include <string_view>
8
10
15
16namespace core {
17
23[[nodiscard]] std::string_view fileName(std::string_view path);
24
35[[nodiscard]] std::string formatLogLine(std::string_view timestamp, LogLevel level,
36 std::string_view category, std::string_view file, int line,
37 std::string_view message);
38
43[[nodiscard]] std::string currentTimestamp();
44
45} // namespace core
Niveaux de journalisation, par gravité croissante.
Espace de noms du moteur et de la logique de jeu.
Definition Bootstrap.h:9
std::string currentTimestamp()
Horodatage courant local, au format "HH:MM:SS".
Definition LogFormat.cpp:44
LogLevel
Niveau d'un message de journalisation (ordre croissant de gravité).
Definition LogLevel.h:14
std::string_view fileName(std::string_view path)
Réduit un chemin source à son seul nom de fichier.
Definition LogFormat.cpp:10
std::string formatLogLine(std::string_view timestamp, LogLevel level, std::string_view category, std::string_view file, int line, std::string_view message)
Compose une ligne de journalisation.
Definition LogFormat.cpp:21