Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- template<typename eT, typename wT, typename iT, typename tT>
- class Logger: public libs::task::Singleton<Logger<eT, wT, iT, tT> > {
- private: friend libs::task::Singleton<Logger<eT, wT, iT, tT> >;
- private: using libs::task::Singleton<Logger<eT, wT, iT, tT> >::Instance;
- // =============================================================================
- // Section for Ctor / Dtor
- // =============================================================================
- private: Logger() {}
- // =============================================================================
- // Section for Implement / Overridden
- // =============================================================================
- // =============================================================================
- // Section for Other methods
- // =============================================================================
- public: template<typename logItemType> inline void error(logItemType item);
- public: template<typename logItemType> inline void warning(logItemType item);
- public: template<typename logItemType> inline void info(logItemType item);
- public: template<typename logItemType> inline void trace(logItemType item);
- public: inline const eT& error() const;
- public: inline const wT& warning() const;
- public: inline const iT& info() const;
- public: inline const tT& trace() const;
- // =============================================================================
- // Section for Member declaration
- // =============================================================================
- private: eT _error;
- private: wT _warning;
- private: iT _info;
- private: tT _trace;
- };
- typedef Logger<MemoryContainer<2, const char*>,
- MemoryContainer<4, const char*>,
- MemoryContainer<10, const char*>,
- MemoryContainer<10, const char*> >
- ConstStrLogger;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement