spdlog
Loading...
Searching...
No Matches
log_msg.h
Go to the documentation of this file.
1// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
2// Distributed under the MIT License (http://opensource.org/licenses/MIT)
3
4#pragma once
5
6#include <spdlog/common.h>
7#include <string>
8
9namespace spdlog {
10namespace details {
12{
13 log_msg() = default;
14 log_msg(log_clock::time_point log_time, source_loc loc, string_view_t logger_name, level::level_enum lvl, string_view_t msg);
17 log_msg(const log_msg &other) = default;
18 log_msg &operator=(const log_msg &other) = default;
19
21 level::level_enum level{level::off};
22 log_clock::time_point time;
23 size_t thread_id{0};
24
25 // wrapping the formatted text with color (updated by pattern_formatter).
26 mutable size_t color_range_start{0};
27 mutable size_t color_range_end{0};
28
31};
32} // namespace details
33} // namespace spdlog
34
35#ifdef SPDLOG_HEADER_ONLY
36# include "log_msg-inl.h"
37#endif
#define SPDLOG_API
Definition common.h:31
Definition async.h:25
fmt::basic_string_view< char > string_view_t
Definition common.h:114
log_msg & operator=(const log_msg &other)=default
log_clock::time_point time
Definition log_msg.h:22
string_view_t payload
Definition log_msg.h:30
log_msg(log_clock::time_point log_time, source_loc loc, string_view_t logger_name, level::level_enum lvl, string_view_t msg)
string_view_t logger_name
Definition log_msg.h:20
log_msg(const log_msg &other)=default