Kea 2.7.5
isc::db::DbLogger Class Reference

Database logger class. More...

#include <db_log.h>

Public Types

typedef std::map< DbMessageID, isc::log::MessageIDMessageMap
 Translation map type.
 

Public Member Functions

 DbLogger (isc::log::Logger &logger, const MessageMap &map)
 Constructor.
 
const isc::log::MessageIDtranslateMessage (const DbMessageID &id) const
 Translate message.
 

Public Attributes

isc::log::Loggerlogger_
 The logger.
 
const MessageMapmap_
 The translation map.
 

Detailed Description

Database logger class.

Definition at line 74 of file db_log.h.

Member Typedef Documentation

◆ MessageMap

Translation map type.

Definition at line 77 of file db_log.h.

Constructor & Destructor Documentation

◆ DbLogger()

isc::db::DbLogger::DbLogger ( isc::log::Logger & logger,
const MessageMap & map )
inline

Constructor.

Parameters
loggerlogger which will be called
mapmessage id translation map

Definition at line 83 of file db_log.h.

Member Function Documentation

◆ translateMessage()

const MessageID & isc::db::DbLogger::translateMessage ( const DbMessageID & id) const

Translate message.

Parameters
iddatabase message id
Returns
logger message
Exceptions
Unexpectedif the id is not in the message map

Definition at line 53 of file db_log.cc.

References isc_throw, and map_.

Member Data Documentation

◆ logger_

isc::log::Logger& isc::db::DbLogger::logger_

The logger.

Definition at line 95 of file db_log.h.

◆ map_

const MessageMap& isc::db::DbLogger::map_

The translation map.

Definition at line 98 of file db_log.h.

Referenced by translateMessage().


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