The Battle for Wesnoth  1.15.12+dev
Public Member Functions | Private Member Functions | Private Attributes | List of all members
lg::scope_logger Class Reference

#include <log.hpp>

Public Member Functions

 scope_logger (const log_domain &domain, const char *str)
 
 scope_logger (const log_domain &domain, const std::string &str)
 
 ~scope_logger ()
 

Private Member Functions

void do_log_entry (const std::string &str) noexcept
 
void do_log_exit () noexcept
 

Private Attributes

int64_t ticks_
 
const log_domaindomain_
 
std::string str_
 

Detailed Description

Definition at line 164 of file log.hpp.

Constructor & Destructor Documentation

◆ scope_logger() [1/2]

lg::scope_logger::scope_logger ( const log_domain domain,
const char *  str 
)
inline

Definition at line 170 of file log.hpp.

References lg::debug().

◆ scope_logger() [2/2]

lg::scope_logger::scope_logger ( const log_domain domain,
const std::string &  str 
)
inline

Definition at line 177 of file log.hpp.

References lg::debug().

◆ ~scope_logger()

lg::scope_logger::~scope_logger ( )
inline

Definition at line 184 of file log.hpp.

References lg::wml_error().

Member Function Documentation

◆ do_log_entry()

void lg::scope_logger::do_log_entry ( const std::string &  str)
privatenoexcept

Definition at line 265 of file log.cpp.

References lg::debug(), and indent.

◆ do_log_exit()

void lg::scope_logger::do_log_exit ( )
privatenoexcept

Definition at line 275 of file log.cpp.

References lg::debug(), indent, output(), and timestamp.

Member Data Documentation

◆ domain_

const log_domain& lg::scope_logger::domain_
private

Definition at line 167 of file log.hpp.

◆ str_

std::string lg::scope_logger::str_
private

Definition at line 168 of file log.hpp.

◆ ticks_

int64_t lg::scope_logger::ticks_
private

Definition at line 166 of file log.hpp.


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