neoGFX
Cross-platform C++ app/game engine
Loading...
Searching...
No Matches
neolib::logger::logger< Instance > Class Template Referenceabstract

#include <logger.hpp>

Inheritance diagram for neolib::logger::logger< Instance >:
neolib::logger::i_logger neolib::lifetime< Base > neolib::services::i_service neolib::i_lifetime neolib::logger::basic_ostream_logger< Instance, CharT, Traits >

Public Member Functions

 logger ()
 
 ~logger ()
 
void copy_to (i_logger &aLogger) final
 
void cancel_copy_to (i_logger &aLogger) final
 
bool has_logging_thread () const final
 
void create_logging_thread () final
 
severity filter_severity () const final
 
void set_filter_severity (severity aSeverity) final
 
void register_category (category_id aId, i_string const &aName) final
 
bool category_enabled (category_id aId) const final
 
void enable_category (category_id aId) final
 
void disable_category (category_id aId) final
 
bool has_formatter () const final
 
i_formatterformatter () const final
 
void set_formatter (i_formatter &aFormatter) final
 
void clear_formatter () final
 
line_id_t line_id () const final
 
void reset_line_id (line_id_t aLineId=DefaultInitialLineId) final
 
i_loggeroperator<< (severity aSeverity) final
 
i_loggeroperator<< (category_id aCategory) final
 
void commit () override
 
void wait () const final
 
virtual void register_category (category_id aId, i_string const &aName)=0
 
template<typename IdType >
void register_category (IdType aId, std::string const &aName={})
 
virtual bool category_enabled (category_id aId) const=0
 
template<typename IdType >
void category_enabled (IdType aId)
 
virtual void enable_category (category_id aId)=0
 
template<typename IdType >
void enable_category (IdType aId)
 
virtual void disable_category (category_id aId)=0
 
template<typename IdType >
void disable_category (IdType aId)
 
virtual i_loggeroperator<< (severity aSeverity)=0
 
virtual i_loggeroperator<< (category_id aCategory)=0
 
i_loggeroperator<< (category aCategory)
 
i_loggeroperator<< (endl_t)
 
i_loggeroperator<< (flush_t)
 
template<typename T >
i_loggeroperator<< (T const &aValue)
 
- Public Member Functions inherited from neolib::logger::i_logger
virtual ~i_logger ()=default
 
template<typename IdType >
void register_category (IdType aId, std::string const &aName={})
 
template<typename IdType >
void category_enabled (IdType aId)
 
template<typename IdType >
void enable_category (IdType aId)
 
template<typename IdType >
void disable_category (IdType aId)
 
i_loggeroperator<< (category aCategory)
 
i_loggeroperator<< (endl_t)
 
i_loggeroperator<< (flush_t)
 
template<typename T >
i_loggeroperator<< (T const &aValue)
 
- Public Member Functions inherited from neolib::services::i_service
virtual ~i_service ()=default
 
- Public Member Functions inherited from neolib::lifetime< Base >
 lifetime (lifetime_state aState=lifetime_state::Alive)
 
virtual ~lifetime ()
 
lifetime_state object_state () const final
 
std::shared_ptr< std::atomic< lifetime_state > > object_state_ptr () const final
 
bool is_creating () const final
 
bool is_alive () const final
 
bool is_destroying () const final
 
bool is_destroyed () const final
 
void set_alive () override
 
void set_destroying () override
 
void set_destroyed () override
 
- Public Member Functions inherited from neolib::i_lifetime
virtual ~i_lifetime ()=default
 

Static Public Member Functions

static uuid constiid ()
 

Protected Member Functions

std::recursive_mutex & mutex () const
 
std::mutex & commit_signal_mutex () const
 
std::condition_variable & commit_signal () const
 
void join_logging_thread ()
 
severity message_severity () const
 
void set_message_severity (severity aMessageSeverity)
 
category_id message_category () const
 
void set_message_category (category_id aid)
 
bool message_category_enabled () const
 
void flush (i_string const &aMessage) final
 
virtual void commit (buffer_t const &aBuffer)=0
 
void finalize ()
 

Additional Inherited Members

- Public Types inherited from neolib::lifetime< Base >
typedef neolib::destroyed_flag destroyed_flag
 

Detailed Description

template<std::size_t Instance = 0>
class neolib::logger::logger< Instance >

Definition at line 55 of file logger.hpp.

Constructor & Destructor Documentation

◆ logger()

template<std::size_t Instance = 0>
neolib::logger::logger< Instance >::logger ( )
inline

Definition at line 67 of file logger.hpp.

◆ ~logger()

template<std::size_t Instance = 0>
neolib::logger::logger< Instance >::~logger ( )
inline

Definition at line 70 of file logger.hpp.

Member Function Documentation

◆ cancel_copy_to()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::cancel_copy_to ( i_logger< Instance > &  aLogger)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 80 of file logger.hpp.

◆ category_enabled() [1/3]

template<std::size_t Instance = 0>
bool neolib::logger::logger< Instance >::category_enabled ( category_id  aId) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 130 of file logger.hpp.

◆ category_enabled() [2/3]

template<std::size_t Instance = 0>
virtual bool neolib::logger::i_logger::category_enabled ( category_id  aId) const
virtual

◆ category_enabled() [3/3]

template<std::size_t Instance = 0>
template<typename IdType >
void neolib::logger::i_logger::category_enabled ( IdType  aId)
inline

Definition at line 172 of file i_logger.hpp.

◆ clear_formatter()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::clear_formatter ( )
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 172 of file logger.hpp.

◆ commit() [1/2]

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::commit ( )
inlineoverridevirtual

Implements neolib::logger::i_logger.

Definition at line 245 of file logger.hpp.

◆ commit() [2/2]

template<std::size_t Instance = 0>
virtual void neolib::logger::logger< Instance >::commit ( buffer_t const aBuffer)
protectedpure virtual

◆ commit_signal()

template<std::size_t Instance = 0>
std::condition_variable & neolib::logger::logger< Instance >::commit_signal ( ) const
inlineprotected

Definition at line 213 of file logger.hpp.

◆ commit_signal_mutex()

template<std::size_t Instance = 0>
std::mutex & neolib::logger::logger< Instance >::commit_signal_mutex ( ) const
inlineprotected

Definition at line 209 of file logger.hpp.

◆ copy_to()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::copy_to ( i_logger< Instance > &  aLogger)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 75 of file logger.hpp.

◆ create_logging_thread()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::create_logging_thread ( )
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 90 of file logger.hpp.

◆ disable_category() [1/3]

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::disable_category ( category_id  aId)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 145 of file logger.hpp.

◆ disable_category() [2/3]

template<std::size_t Instance = 0>
virtual void neolib::logger::i_logger::disable_category ( category_id  aId)
virtual

◆ disable_category() [3/3]

template<std::size_t Instance = 0>
template<typename IdType >
void neolib::logger::i_logger::disable_category ( IdType  aId)
inline

Definition at line 182 of file i_logger.hpp.

◆ enable_category() [1/3]

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::enable_category ( category_id  aId)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 136 of file logger.hpp.

◆ enable_category() [2/3]

template<std::size_t Instance = 0>
virtual void neolib::logger::i_logger::enable_category ( category_id  aId)
virtual

◆ enable_category() [3/3]

template<std::size_t Instance = 0>
template<typename IdType >
void neolib::logger::i_logger::enable_category ( IdType  aId)
inline

Definition at line 177 of file i_logger.hpp.

◆ filter_severity()

template<std::size_t Instance = 0>
severity neolib::logger::logger< Instance >::filter_severity ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 108 of file logger.hpp.

◆ finalize()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::finalize ( )
inlineprotected

Definition at line 317 of file logger.hpp.

◆ flush()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::flush ( i_string const aMessage)
inlinefinalprotectedvirtual

Implements neolib::logger::i_logger.

Definition at line 285 of file logger.hpp.

◆ formatter()

template<std::size_t Instance = 0>
i_formatter & neolib::logger::logger< Instance >::formatter ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 160 of file logger.hpp.

◆ has_formatter()

template<std::size_t Instance = 0>
bool neolib::logger::logger< Instance >::has_formatter ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 155 of file logger.hpp.

◆ has_logging_thread()

template<std::size_t Instance = 0>
bool neolib::logger::logger< Instance >::has_logging_thread ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 85 of file logger.hpp.

◆ iid()

template<std::size_t Instance = 0>
static uuid const & neolib::logger::logger< Instance >::iid ( )
inlinestatic

Definition at line 417 of file logger.hpp.

◆ join_logging_thread()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::join_logging_thread ( )
inlineprotected

Definition at line 217 of file logger.hpp.

◆ line_id()

template<std::size_t Instance = 0>
line_id_t neolib::logger::logger< Instance >::line_id ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 178 of file logger.hpp.

◆ message_category()

template<std::size_t Instance = 0>
category_id neolib::logger::logger< Instance >::message_category ( ) const
inlineprotected

Definition at line 230 of file logger.hpp.

◆ message_category_enabled()

template<std::size_t Instance = 0>
bool neolib::logger::logger< Instance >::message_category_enabled ( ) const
inlineprotected

Definition at line 238 of file logger.hpp.

◆ message_severity()

template<std::size_t Instance = 0>
severity neolib::logger::logger< Instance >::message_severity ( ) const
inlineprotected

Definition at line 222 of file logger.hpp.

◆ mutex()

template<std::size_t Instance = 0>
std::recursive_mutex & neolib::logger::logger< Instance >::mutex ( ) const
inlineprotected

Definition at line 205 of file logger.hpp.

◆ operator<<() [1/8]

template<std::size_t Instance = 0>
i_logger & neolib::logger::i_logger::operator<< ( category  aCategory)
inline

Definition at line 187 of file i_logger.hpp.

◆ operator<<() [2/8]

template<std::size_t Instance = 0>
i_logger & neolib::logger::logger< Instance >::operator<< ( category_id  aCategory)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 196 of file logger.hpp.

◆ operator<<() [3/8]

template<std::size_t Instance = 0>
virtual i_logger & neolib::logger::i_logger::operator<< ( category_id  aCategory)
virtual

◆ operator<<() [4/8]

template<std::size_t Instance = 0>
i_logger & neolib::logger::i_logger::operator<< ( endl_t  )
inline

Definition at line 191 of file i_logger.hpp.

◆ operator<<() [5/8]

template<std::size_t Instance = 0>
i_logger & neolib::logger::i_logger::operator<< ( flush_t  )
inline

Definition at line 199 of file i_logger.hpp.

◆ operator<<() [6/8]

template<std::size_t Instance = 0>
i_logger & neolib::logger::logger< Instance >::operator<< ( severity  aSeverity)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 188 of file logger.hpp.

◆ operator<<() [7/8]

template<std::size_t Instance = 0>
virtual i_logger & neolib::logger::i_logger::operator<< ( severity  aSeverity)
virtual

◆ operator<<() [8/8]

template<std::size_t Instance = 0>
template<typename T >
i_logger & neolib::logger::i_logger::operator<< ( T const aValue)
inline

Definition at line 208 of file i_logger.hpp.

◆ register_category() [1/3]

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::register_category ( category_id  aId,
i_string const aName 
)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 122 of file logger.hpp.

◆ register_category() [2/3]

template<std::size_t Instance = 0>
virtual void neolib::logger::i_logger::register_category ( category_id  aId,
i_string const aName 
)
virtual

◆ register_category() [3/3]

template<std::size_t Instance = 0>
template<typename IdType >
void neolib::logger::i_logger::register_category ( IdType  aId,
std::string const aName = {} 
)
inline

Definition at line 167 of file i_logger.hpp.

◆ reset_line_id()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::reset_line_id ( line_id_t  aLineId = DefaultInitialLineId)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 182 of file logger.hpp.

◆ set_filter_severity()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::set_filter_severity ( severity  aSeverity)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 113 of file logger.hpp.

◆ set_formatter()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::set_formatter ( i_formatter aFormatter)
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 167 of file logger.hpp.

◆ set_message_category()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::set_message_category ( category_id  aid)
inlineprotected

Definition at line 234 of file logger.hpp.

◆ set_message_severity()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::set_message_severity ( severity  aMessageSeverity)
inlineprotected

Definition at line 226 of file logger.hpp.

◆ wait()

template<std::size_t Instance = 0>
void neolib::logger::logger< Instance >::wait ( ) const
inlinefinalvirtual

Implements neolib::logger::i_logger.

Definition at line 273 of file logger.hpp.


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