TRIQS/TRIQS 4.0.0
Researching Interacting Quantum Systems
Loading...
Searching...
No Matches
triqs::utility::indented_ostream

#include <triqs/utility/report_stream.hpp>

Detailed Description

Adapter for std::ostream that prepends a fixed-width indentation to every new line.

It inherits from std::ostream and substitutes a custom std::streambuf that injects a given number of spaces at the start of every line. Useful for nesting verbose output without manually padding each string.

Definition at line 104 of file report_stream.hpp.

Public Member Functions

 indented_ostream (std::ostream &os, int indent)
 Construct an indented stream on top of an existing ostream with a given indentation width.

Constructor & Destructor Documentation

◆ indented_ostream()

triqs::utility::indented_ostream::indented_ostream ( std::ostream & os,
int indent )
inline

Construct an indented stream on top of an existing ostream with a given indentation width.

Parameters
osUnderlying std::ostream that receives the indented output.
indentNumber of spaces inserted at the start of each line.

Definition at line 132 of file report_stream.hpp.


The documentation for this class was generated from the following file: