Public Member Functions | Static Public Member Functions | Protected Attributes | Private Member Functions | List of all members
gnsstk::Log< T > Class Template Reference

Detailed Description

template<class T>
class gnsstk::Log< T >

template class Log is used by classes ConfigureLOG and ConfigureLOGstream. class ConfigureLOGstream is just class Log with template type = ConfigureLOGstream

Definition at line 66 of file logstream.hpp.

#include <logstream.hpp>

Public Member Functions

 Log ()
 
std::ostringstream & Put (LogLevel level=INFO)
 write out to log stream at level, default is INFO More...
 
virtual ~Log ()
 

Static Public Member Functions

static LogLevel FromString (const std::string &level)
 convert from a string (= names in the LogLevel enum) to a LogLevel More...
 
static LogLevelReportingLevel ()
 get/set the highest level that is actually output to log stream More...
 
static bool & ReportLevels ()
 get/set; if true, output level on each line, after the time tag More...
 
static bool & ReportTimeTags ()
 get/set; if true, output time tag on each line, first More...
 
static std::string ToString (LogLevel level)
 convert a level to a string corresponding to the LogLevel enum More...
 

Protected Attributes

std::ostringstream os
 string stream to which output is written; destructor will dump to log stream. More...
 

Private Member Functions

 Log (const Log &)
 do not implement More...
 
std::string NowTime (void)
 generate a timetag as string More...
 
Logoperator= (const Log &)
 do not implement More...
 

Constructor & Destructor Documentation

◆ Log() [1/2]

template<class T >
gnsstk::Log< T >::Log ( )
inline

Definition at line 69 of file logstream.hpp.

◆ ~Log()

template<class T >
gnsstk::Log< T >::~Log
virtual

Definition at line 112 of file logstream.hpp.

◆ Log() [2/2]

template<class T >
gnsstk::Log< T >::Log ( const Log< T > &  )
private

do not implement

Member Function Documentation

◆ FromString()

template<class T >
LogLevel gnsstk::Log< T >::FromString ( const std::string &  level)
static

convert from a string (= names in the LogLevel enum) to a LogLevel

Definition at line 150 of file logstream.hpp.

◆ NowTime()

template<class T >
std::string gnsstk::Log< T >::NowTime ( void  )
inlineprivate

generate a timetag as string

Definition at line 196 of file logstream.hpp.

◆ operator=()

template<class T >
Log& gnsstk::Log< T >::operator= ( const Log< T > &  )
private

do not implement

◆ Put()

template<class T >
std::ostringstream & gnsstk::Log< T >::Put ( LogLevel  level = INFO)

write out to log stream at level, default is INFO

Definition at line 101 of file logstream.hpp.

◆ ReportingLevel()

template<class T >
LogLevel & gnsstk::Log< T >::ReportingLevel
static

get/set the highest level that is actually output to log stream

Definition at line 134 of file logstream.hpp.

◆ ReportLevels()

template<class T >
bool & gnsstk::Log< T >::ReportLevels
static

get/set; if true, output level on each line, after the time tag

Definition at line 118 of file logstream.hpp.

◆ ReportTimeTags()

template<class T >
bool & gnsstk::Log< T >::ReportTimeTags
static

get/set; if true, output time tag on each line, first

Definition at line 126 of file logstream.hpp.

◆ ToString()

template<class T >
std::string gnsstk::Log< T >::ToString ( LogLevel  level)
static

convert a level to a string corresponding to the LogLevel enum

Definition at line 142 of file logstream.hpp.

Member Data Documentation

◆ os

template<class T >
std::ostringstream gnsstk::Log< T >::os
protected

string stream to which output is written; destructor will dump to log stream.

Definition at line 87 of file logstream.hpp.


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


gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:45