Changeset 853 for library/bdm/bdmroot.h
- Timestamp:
- 03/05/10 11:12:07 (14 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
library/bdm/bdmroot.h
r850 r853 38 38 void UI_DBG (const Setting &S, const string &spc, ostream &out ); 39 39 40 41 40 //! level of details that will be logged to a logger 42 41 // DULEZITE TODO - zde musi respektovat aktualne ulozene hodnoty, tj. nacist je, pak pridat … … 53 52 bitset<32> values; 54 53 55 virtualconst Array<string> &names() const56 { 57 return T:: __option_names();54 const Array<string> &names() const 55 { 56 return T::option_names(); 58 57 } 59 58 … … 77 76 78 77 // MUZEME INTERNE POUZIVAT ENUMY, A KLIDNE MENIT JEJICH PORADI, DIKY TOMUHLE MAKRU SE VZDY NAMAPUJI NA TY SPRAVNE STRINGY 79 #define LOG_LEVEL(CLASSNAME,...) private: friend class logged_options<CLASSNAME>; static const Array<string> & __option_names() { static const Array<string> option_names( "{"#__VA_ARGS__"}" ); return option_names; }; public: enum possible_options { __VA_ARGS__ }; logged_options<CLASSNAME> log_level;78 #define LOG_LEVEL(CLASSNAME,...) private: friend class logged_options<CLASSNAME>; static const Array<string> &option_names() { static const Array<string> option_names( "{"#__VA_ARGS__"}" ); return option_names; }; public: enum possible_options { __VA_ARGS__ }; logged_options<CLASSNAME> log_level; 80 79 81 80 //forward declaration … … 96 95 //! Root class of BDM objects 97 96 class root { 97 private: 98 //! It is necessary to allow calling of from_setting and to_setting within the UI class ++ i log_options 99 friend class UI; 100 101 // TODO okomentovat 102 static const Array<string> &option_names() 103 { 104 static const Array<string> option_names; 105 return option_names; 106 }; 107 98 108 protected: 99 109 //! record of connections to the logger 100 110 log_record* logrec; 101 102 //! It is necessary to allow calling of from_setting and to_setting within the UI class103 friend class UI;104 111 105 112 /*! … … 182 189 183 190 public: 184 enum possible_options{}; 191 // TODO okomentovat 192 enum possible_options { }; 193 185 194 //!default constructor 186 195 root() : logrec ( NULL ) {};