Back to index

im-sdk  12.3.91
Classes | Defines | Functions
IMLog.hh File Reference
#include <stdarg.h>
#include <stdio.h>
#include "basictype.hh"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  IMLog

Defines

#define IMLOG_DEFINE_FUNC(fn, lv, sl)

Functions

void IMLog_output (enum IMLog::LOG_LEVEL lv, enum IMLog::LOG_DESTINATION d, const char *fmt,...)
 IMLOG_DEFINE_FUNC (LOG_CRITICAL, IMLog::ERROR, IMLog::SYSLOG_USER)
 IMLOG_DEFINE_FUNC (LOG_ERROR, IMLog::ERROR, IMLog::IMLOG_DEFAULT)
 IMLOG_DEFINE_FUNC (LOG_WARNING, IMLog::WARNING, IMLog::IMLOG_DEFAULT)
 IMLOG_DEFINE_FUNC (LOG_NORMAL, IMLog::NORMAL, IMLog::IMLOG_DEFAULT)
 IMLOG_DEFINE_FUNC (LOG_INFO, IMLog::INFO, IMLog::IMLOG_DEFAULT)
 IMLOG_DEFINE_FUNC (LOG_VERBOSE, IMLog::VERBOSE, IMLog::IMLOG_DEFAULT)
 IMLOG_DEFINE_FUNC (LOG_DEBUG, IMLog::DEBUGLOG, IMLog::IMLOG_DEFAULT)

Define Documentation

#define IMLOG_DEFINE_FUNC (   fn,
  lv,
  sl 
)
Value:
inline void fn(const char *fmt, ...) \
{ \
    va_list va; \
    IMLog *pimlog = IMLog::get_instance(); \
\
    if (!(pimlog->check(lv))) return; \
    va_start(va, fmt); \
    pimlog->voutput((lv), IMLog::IMLOG_DEFAULT, fmt, va); \
    if (sl != IMLog::IMLOG_DEFAULT) pimlog->voutput((lv), (sl), fmt, va); \
    va_end(va); \
}

Definition at line 116 of file IMLog.hh.


Function Documentation

IMLOG_DEFINE_FUNC ( LOG_CRITICAL  ,
IMLog::ERROR  ,
IMLog::SYSLOG_USER   
)
void IMLog_output ( enum IMLog::LOG_LEVEL  lv,
enum IMLog::LOG_DESTINATION  d,
const char *  fmt,
  ... 
) [inline]

Definition at line 100 of file IMLog.hh.

{
    va_list va;
    IMLog *pimlog = IMLog::get_instance();

    if (!(pimlog->check(lv))) return;
    va_start(va, fmt);
    pimlog->voutput(lv, d, fmt, va);
    va_end(va);
}