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
4
7
8namespace logit {
9
16 public:
17 virtual ~ILogFormatter() = default;
18
25 virtual void set_timestamp_offset(int64_t offset_ms) = 0;
26
34 virtual std::string format(const LogRecord& record) const = 0;
35 }; // ILogFormatter
36
37}; // namespace logit
38
39#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:14