Logger System 0.1.3
High-performance C++20 thread-safe logging system with asynchronous capabilities
Loading...
Searching...
No Matches
formatted_writer.h File Reference

Decorator that applies formatting to wrapped log writers. More...

Include dependency graph for formatted_writer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  kcenon::logger::formatted_writer
 Decorator that applies a formatter to a wrapped writer. More...
 

Namespaces

namespace  kcenon
 
namespace  kcenon::logger
 

Functions

std::unique_ptr< formatted_writerkcenon::logger::make_formatted_writer (std::unique_ptr< log_writer_interface > writer, std::unique_ptr< log_formatter_interface > formatter)
 Factory function to create a formatted writer.
 

Detailed Description

Decorator that applies formatting to wrapped log writers.

Author
kcenon
Since
4.0.0

This file defines the formatted_writer class, a Decorator pattern implementation that wraps any log_writer_interface and applies a formatter before delegating writes. This enables composable formatting at the writer level, allowing different formats for different output destinations.

Part of the Decorator pattern refactoring (#356).

Definition in file formatted_writer.h.