hydrogen 1.1.1
Object.h File Reference

Data Structures

class  Object
 Base class. More...
 
struct  Object::obj_cpt_t
 an objects class map item type More...
 

Namespaces

namespace  H2Core
 

Macros

#define H2_OBJECT
 
#define __LOG_METHOD( lvl, msg)   if( __logger->should_log( (lvl) ) ) { __logger->log( (lvl), class_name(), __FUNCTION__, msg ); }
 
#define __LOG_CLASS( lvl, msg)   if( logger()->should_log( (lvl) ) ) { logger()->log( (lvl), class_name(), __FUNCTION__, msg ); }
 
#define __LOG_OBJ( lvl, msg)   if( __object->logger()->should_log( (lvl) ) ) { __object->logger()->log( (lvl), 0, __PRETTY_FUNCTION__, msg ); }
 
#define __LOG_STATIC( lvl, msg)   if( H2Core::Logger::get_instance()->should_log( (lvl) ) ) { H2Core::Logger::get_instance()->log( (lvl), 0, __PRETTY_FUNCTION__, msg ); }
 
#define __LOG(logger, lvl, msg)   if( (logger)->should_log( (lvl) ) ) { (logger)->log( (lvl), 0, 0, msg ); }
 
#define DEBUGLOG(x)   __LOG_METHOD( H2Core::Logger::Debug, (x) );
 
#define INFOLOG(x)   __LOG_METHOD( H2Core::Logger::Info, (x) );
 
#define WARNINGLOG(x)   __LOG_METHOD( H2Core::Logger::Warning, (x) );
 
#define ERRORLOG(x)   __LOG_METHOD( H2Core::Logger::Error, (x) );
 
#define _DEBUGLOG(x)   __LOG_CLASS( H2Core::Logger::Debug, (x) );
 
#define _INFOLOG(x)   __LOG_CLASS( H2Core::Logger::Info, (x) );
 
#define _WARNINGLOG(x)   __LOG_CLASS( H2Core::Logger::Warning, (x) );
 
#define _ERRORLOG(x)   __LOG_CLASS( H2Core::Logger::Error, (x) );
 
#define __DEBUGLOG(x)   __LOG_OBJ( H2Core::Logger::Debug, (x) );
 
#define __INFOLOG(x)   __LOG_OBJ( H2Core::Logger::Info, (x) );
 
#define __WARNINGLOG(x)   __LOG_OBJ( H2Core::Logger::Warning, (x) );
 
#define __ERRORLOG(x)   __LOG_OBJ( H2Core::Logger::Error, (x) );
 
#define ___DEBUGLOG(x)   __LOG_STATIC( H2Core::Logger::Debug, (x) );
 
#define ___INFOLOG(x)   __LOG_STATIC( H2Core::Logger::Info, (x) );
 
#define ___WARNINGLOG(x)   __LOG_STATIC(H2Core::Logger::Warning, (x) );
 
#define ___ERRORLOG(x)   __LOG_STATIC( H2Core::Logger::Error, (x) );
 

Functions

std::ostream & operator<< (std::ostream &os, const Object &object)
 
std::ostream & operator<< (std::ostream &os, const Object *object)
 
QDebug operator<< (QDebug d, Object *o)
 
QDebug operator<< (QDebug d, std::shared_ptr< Object > o)
 

Macro Definition Documentation

◆ ___DEBUGLOG

#define ___DEBUGLOG (   x)    __LOG_STATIC( H2Core::Logger::Debug, (x) );

◆ ___ERRORLOG

#define ___ERRORLOG (   x)    __LOG_STATIC( H2Core::Logger::Error, (x) );

◆ ___INFOLOG

#define ___INFOLOG (   x)    __LOG_STATIC( H2Core::Logger::Info, (x) );

◆ ___WARNINGLOG

#define ___WARNINGLOG (   x)    __LOG_STATIC(H2Core::Logger::Warning, (x) );

◆ __DEBUGLOG

#define __DEBUGLOG (   x)    __LOG_OBJ( H2Core::Logger::Debug, (x) );

◆ __ERRORLOG

#define __ERRORLOG (   x)    __LOG_OBJ( H2Core::Logger::Error, (x) );

◆ __INFOLOG

#define __INFOLOG (   x)    __LOG_OBJ( H2Core::Logger::Info, (x) );

◆ __LOG

#define __LOG (   logger,
  lvl,
  msg 
)    if( (logger)->should_log( (lvl) ) ) { (logger)->log( (lvl), 0, 0, msg ); }

◆ __LOG_CLASS

#define __LOG_CLASS (   lvl,
  msg 
)    if( logger()->should_log( (lvl) ) ) { logger()->log( (lvl), class_name(), __FUNCTION__, msg ); }

◆ __LOG_METHOD

#define __LOG_METHOD (   lvl,
  msg 
)    if( __logger->should_log( (lvl) ) ) { __logger->log( (lvl), class_name(), __FUNCTION__, msg ); }

◆ __LOG_OBJ

#define __LOG_OBJ (   lvl,
  msg 
)    if( __object->logger()->should_log( (lvl) ) ) { __object->logger()->log( (lvl), 0, __PRETTY_FUNCTION__, msg ); }

◆ __LOG_STATIC

#define __LOG_STATIC (   lvl,
  msg 
)    if( H2Core::Logger::get_instance()->should_log( (lvl) ) ) { H2Core::Logger::get_instance()->log( (lvl), 0, __PRETTY_FUNCTION__, msg ); }

◆ __WARNINGLOG

#define __WARNINGLOG (   x)    __LOG_OBJ( H2Core::Logger::Warning, (x) );

◆ _DEBUGLOG

#define _DEBUGLOG (   x)    __LOG_CLASS( H2Core::Logger::Debug, (x) );

◆ _ERRORLOG

#define _ERRORLOG (   x)    __LOG_CLASS( H2Core::Logger::Error, (x) );

◆ _INFOLOG

#define _INFOLOG (   x)    __LOG_CLASS( H2Core::Logger::Info, (x) );

◆ _WARNINGLOG

#define _WARNINGLOG (   x)    __LOG_CLASS( H2Core::Logger::Warning, (x) );

◆ DEBUGLOG

#define DEBUGLOG (   x)    __LOG_METHOD( H2Core::Logger::Debug, (x) );

◆ ERRORLOG

#define ERRORLOG (   x)    __LOG_METHOD( H2Core::Logger::Error, (x) );

◆ H2_OBJECT

#define H2_OBJECT
Value:
public: static const char* class_name() { return __class_name; } \
private: static const char* __class_name; \

◆ INFOLOG

#define INFOLOG (   x)    __LOG_METHOD( H2Core::Logger::Info, (x) );

◆ WARNINGLOG

#define WARNINGLOG (   x)    __LOG_METHOD( H2Core::Logger::Warning, (x) );