log4tango::LoggerStream(3)

πŸ“¦
version 9.3.4 Β· 2 versions
, in debian bookworm

πŸ’… log4tango::LoggerStream πŸ’…

okay bestie, so this is a page from the log4tango manual, section 3 β€” yeah, the library-functions section, the good one ✨. Sit down, grab a boba, we're gonna talk about a stream that logs. It's giving "std::ostream but it's a Logger." Iconic behaviour, honestly.


✨ NAME ✨

log4tango::LoggerStream β€” the stream class that pipes your vibes straight into a Logger 🫢


🌸 SYNOPSIS 🌸

#include <LoggerStream.hh>

πŸ‘‘ Public Member Functions πŸ‘‘

  • LOG4TANGO_EXPORT LoggerStream (Logger &logger, Level::Value level, bool filter=true) β€” builds you a LoggerStream for the given Logger at the given level πŸŽ€
  • LOG4TANGO_EXPORT ~LoggerStream () β€” the destructor for LoggerStream&) πŸ’€
  • LOG4TANGO_EXPORT Logger & get_logger (void) const β€” hands you back the destination Logger this stream is feeding 🌈
  • LOG4TANGO_EXPORT Level::Value get_level (void) const β€” hands you back the level for this stream ⭐
  • LOG4TANGO_EXPORT LoggerStream & operator<< (LOG4TANGO_UNUSED(LogInitiator &i)) β€” streams in an Initiator πŸ’–
  • LOG4TANGO_EXPORT LoggerStream & operator<< (LOG4TANGO_UNUSED(LogSeparator &s)) β€” streams in a Separator. Sends the contents of the stream buffer to the Logger with set level and empties the buffer. 🧚
  • LOG4TANGO_EXPORT LoggerStream & operator<< (LOG4TANGO_UNUSED(ls_terminator endoflog)) β€” streams in a ls_manipulator πŸ¦‹
  • LOG4TANGO_EXPORT void flush (void) β€” flushes the contents of the stream buffer to the Logger and empties the buffer πŸ”₯
  • LOG4TANGO_EXPORT LoggerStream & operator<< (std::ios_base &(*_F)(std::ios_base &)) β€” streams in a std stream manipulator 😌
  • template<typename T > LoggerStream & operator<< (const T &t) β€” stream in arbitrary types and objects, no cap πŸ’…

πŸŽ€ Constructor & Destructor Documentation πŸŽ€

log4tango::LoggerStream::LoggerStream (Logger & logger, Level::Value level, bool filter = true)

Construct a LoggerStream for given Logger with given level. Like, you tell it where to log and how loud ✨

Parameters

  • logger β€” The logger this stream will send log messages to. πŸ“¬
  • level β€” The level the log messages will get or Level::NOTSET to silently discard any streamed in messages. (yes bestie, NOTSET = it goes straight into the void πŸ•³οΈ)
  • filter β€” The filter flag 🚦

log4tango::LoggerStream::~LoggerStream ()

Destructor for LoggerStream&) πŸ’€ bye babes, thanks for the logs


πŸ¦‹ Member Function Documentation πŸ¦‹

void log4tango::LoggerStream::flush (void)

Flush the contents of the stream buffer to the Logger and empties the buffer. 🚰

LOG4TANGO_EXPORT Level::Value log4tango::LoggerStream::get_level (void) const [inline]

Returns the level for this stream.

Returns

  • The level. πŸ‘‘

LOG4TANGO_EXPORT Logger & log4tango::LoggerStream::get_logger (void) const [inline]

Returns the destination Logger for this stream.

Returns

  • The Logger. 🫢

template<typename T > LoggerStream & log4tango::LoggerStream::operator<< (const T & t) [inline]

Stream in arbitrary types and objects. literally anything you want, it'll take it 🌈

Parameters

  • t β€” The value or object to stream in. πŸ“

Returns

  • A reference to itself. (it's self-referential like that, main character energy fr)

LOG4TANGO_EXPORT LoggerStream & log4tango::LoggerStream::operator<< (LOG4TANGO_UNUSED(LogInitiator &i)) [inline]

Streams in a Initiator. Just a trick to return a ref to self. πŸͺ„

Returns

  • A reference to itself. πŸ’œ

LOG4TANGO_EXPORT LoggerStream & log4tango::LoggerStream::operator<< (LOG4TANGO_UNUSED(LogSeparator &s)) [inline]

Streams in a Separator. Sends the contents of the stream buffer to the Logger with set level and empties the buffer. 🧚

Returns

  • A reference to itself. ✨

LOG4TANGO_EXPORT LoggerStream & log4tango::LoggerStream::operator<< (LOG4TANGO_UNUSED(ls_terminator endoflog)) [inline]

Streams in a ls_manipulator. Sends the contents of the stream buffer to the Logger with set level and empties the buffer. πŸŽ‰

Returns

  • A reference to itself. 🌸

LOG4TANGO_EXPORT LoggerStream & log4tango::LoggerStream::operator<< (std::ios_base &(*)(std::ios_base &) _F) [inline]

Streams in a std stream manipulator.

Parameters

  • _F β€” the manipulator function πŸ› οΈ

Returns

  • a reference to self. ⭐

πŸ’– Author πŸ’–

Generated automatically by Doxygen for log4tango from the source code. πŸ€– (not me writing these by hand, the robots ate, periodt)


okay that's the whole page bestie, and before you go β€” the footer said Version 5.0.2, dated Thu Dec 5 2024, and the manual name is log4tango (section 3, if you forgot already πŸ™ˆ). go log something iconic πŸ’…βœ¨πŸ¦‹

πŸ“¦ where this page comes from