LogIt++
Loading...
Searching...
No Matches
ILogFormatter.hpp
Go to the documentation of this file.
1#pragma once
2#ifndef _LOGIT_ILOG_FORMATTER_HPP_INCLUDED
3#define _LOGIT_ILOG_FORMATTER_HPP_INCLUDED
6
7namespace logit {
8
15 public:
16 virtual ~ILogFormatter() = default;
17
24 virtual void set_timestamp_offset(int64_t offset_ms) = 0;
25
33 virtual std::string format(const LogRecord& record) const = 0;
34 }; // ILogFormatter
35
36}; // namespace logit
37
38#endif // _LOGIT_ILOG_FORMATTER_HPP_INCLUDED
Interface for formatting log records.
virtual ~ILogFormatter()=default
virtual std::string format(const LogRecord &record) const =0
Formats a log record into a string.
virtual void set_timestamp_offset(int64_t offset_ms)=0
Sets the timestamp offset for log formatting.
The primary namespace for the LogIt++ library.
Stores log metadata and content.
Definition LogRecord.hpp:13