Luanti 5.16.0-dev
Loading...
Searching...
No Matches
LogStream Class Reference

#include <log.h>

Collaboration diagram for LogStream:

Public Member Functions

 LogStream ()=delete
 DISABLE_CLASS_COPY (LogStream)
 LogStream (LogTarget &target)
template<typename T>
StreamProxyoperator<< (T &&arg)
StreamProxyoperator<< (std::ostream &(*manip)(std::ostream &))
 operator bool ()
void internalFlush (std::string_view buf)
 operator std::ostream & ()

Private Attributes

LogTargetm_target
StringStreamBuffer< BUFFER_LENGTHm_buffer
DummyStreamBuffer m_dummy_buffer
std::ostream m_stream
std::ostream m_dummy_stream
StreamProxy m_proxy
StreamProxy m_dummy_proxy

Static Private Attributes

static const int BUFFER_LENGTH = 256

Constructor & Destructor Documentation

◆ LogStream() [1/2]

LogStream::LogStream ( )
delete

Referenced by LogStream(), and DISABLE_CLASS_COPY().

Here is the caller graph for this function:

◆ LogStream() [2/2]

LogStream::LogStream ( LogTarget & target)
inline

References LogStream(), internalFlush(), m_buffer, m_dummy_buffer, m_dummy_proxy, m_dummy_stream, m_proxy, m_stream, and m_target.

Here is the call graph for this function:

Member Function Documentation

◆ DISABLE_CLASS_COPY()

LogStream::DISABLE_CLASS_COPY ( LogStream )

References LogStream().

Here is the call graph for this function:

◆ internalFlush()

void LogStream::internalFlush ( std::string_view buf)
inline

References m_target.

Referenced by LogStream().

Here is the caller graph for this function:

◆ operator bool()

LogStream::operator bool ( )
inline

References m_target.

◆ operator std::ostream &()

LogStream::operator std::ostream & ( )
inline

References m_dummy_stream, m_stream, and m_target.

◆ operator<<() [1/2]

StreamProxy & LogStream::operator<< ( std::ostream &(* manip )(std::ostream &))
inline

References m_dummy_proxy, m_proxy, and m_target.

◆ operator<<() [2/2]

template<typename T>
StreamProxy & LogStream::operator<< ( T && arg)
inline

References m_dummy_proxy, m_proxy, and m_target.

Member Data Documentation

◆ BUFFER_LENGTH

const int LogStream::BUFFER_LENGTH = 256
staticprivate

◆ m_buffer

StringStreamBuffer<BUFFER_LENGTH> LogStream::m_buffer
private

Referenced by LogStream().

◆ m_dummy_buffer

DummyStreamBuffer LogStream::m_dummy_buffer
private

Referenced by LogStream().

◆ m_dummy_proxy

StreamProxy LogStream::m_dummy_proxy
private

Referenced by LogStream(), operator<<(), and operator<<().

◆ m_dummy_stream

std::ostream LogStream::m_dummy_stream
private

◆ m_proxy

StreamProxy LogStream::m_proxy
private

Referenced by LogStream(), operator<<(), and operator<<().

◆ m_stream

std::ostream LogStream::m_stream
private

◆ m_target


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