LoggerTypeInterface Class Reference

#include <logger.h>

Inheritance diagram for LoggerTypeInterface:

Detailed Description

Each object of LoggerLine represents an entry in the logger with several meta information. See documentation of members for more information.

Public Member Functions

MAXON_METHOD Result< void > Write (const String &str, const SourceLocation &loc, WRITEMETA level=WRITEMETA::DEFAULT)
 
MAXON_METHOD Result< void > Flush ()
 
 MAXON_OBSERVABLE (void, ObservableLoggerNotify,(const String &str, WRITEMETA level, TARGETAUDIENCE ta), ObservableCombinerRunAllComponent)
 

Private Member Functions

 MAXON_INTERFACE (LoggerTypeInterface, MAXON_REFERENCE_NORMAL, "net.maxon.interface.loggertype")
 
- Private Member Functions inherited from DataDictionaryObjectInterface
MAXON_METHOD Result< void > SetData (ForwardingDataPtr &&key, Data &&data)
 
MAXON_FUNCTION Result< void > SetData (ForwardingDataPtr &&key, const Data &data)
 
MAXON_METHOD Result< DataGetData (const ConstDataPtr &key) const
 
template<typename KEY >
MAXON_FUNCTION Bool Contains (KEY &&key) const
 
MAXON_METHOD Result< void > EraseData (const ConstDataPtr &key)
 
MAXON_METHOD void Reset ()
 
MAXON_METHOD Bool IsEmpty () const
 
MAXON_FUNCTION Bool IsPopulated () const
 
template<typename REFCLASS , typename T = void, typename KEY >
MAXON_FUNCTION Result< typename std::conditional< std::is_void< T >::value, typename IsFidClass< KEY >::type, T >::typeGet (KEY &&key) const
 
template<typename REFCLASS , typename T , typename KEY >
MAXON_FUNCTION std::conditional< IsFidClass< KEY >::value &&GetCollectionKind< T >::value !=COLLECTION_KIND::ARRAY, typename IsFidClass< KEY >::type, T >::type Get (KEY &&key, const T &defaultValue) const
 
template<typename REFCLASS , typename T , typename KEY >
MAXON_FUNCTION std::conditional< IsFidClass< KEY >::value &&GetCollectionKind< T >::value !=COLLECTION_KIND::ARRAY, typename IsFidClass< KEY >::type, T >::type Get (KEY &&key, T &&defaultValue) const
 
template<typename T = void, typename KEY >
MAXON_FUNCTION std::conditional< std::is_void< T >::value, typename IsFidClass< KEY >::type, T >::type GetOrDefault (KEY &&key) const
 
template<typename REFCLASS , typename T , typename KEY >
MAXON_FUNCTION Result< void > Set (KEY &&key, T &&data)
 
template<typename REFCLASS , typename KEY >
MAXON_FUNCTION Result< void > Erase (KEY &&key)
 
MAXON_METHOD void InitIterator (DataDictionaryIteratorInterface *iterator, Bool end) const
 
MAXON_FUNCTION ConstIterator Begin () const
 
MAXON_FUNCTION ConstIterator End () const
 
template<typename T , typename KEY >
std::conditional< std::is_void< T >::value, typename IsFidClass< KEY >::type, T >::type GetOrDefault (KEY &&key) const
 

Additional Inherited Members

- Private Types inherited from DataDictionaryObjectInterface
using Iterator = DataDictionaryIterator
 
using ConstIterator = DataDictionaryIterator
 

Member Function Documentation

◆ MAXON_INTERFACE()

MAXON_INTERFACE ( LoggerTypeInterface  ,
MAXON_REFERENCE_NORMAL  ,
"net.maxon.interface.loggertype"   
)
private

◆ Write()

MAXON_METHOD Result<void> Write ( const String str,
const SourceLocation loc,
WRITEMETA  level = WRITEMETA::DEFAULT 
)

Implement function to consume string and write to a specified destination.

Parameters
[in]strThe string to print. Might not contain
if level is WRITEMETA::NONEWLINE
[in]locSource location where the string entered the logger system.
[in]levelMeta flags

◆ Flush()

MAXON_METHOD Result<void> Flush ( )

Implement function to flush output.

◆ MAXON_OBSERVABLE()

MAXON_OBSERVABLE ( void  ,
ObservableLoggerNotify  ,
(const String &str, WRITEMETA level, TARGETAUDIENCE ta)  ,
ObservableCombinerRunAllComponent   
)

Add observer to get notified once logger type receives a string.

Parameters
[in]strThe string to print. Might not contain
if level is WRITEMETA::NONEWLINE.
[in]locSource location where the string entered the logger system.
[in]taFor which audience is the string intended.