source:
molecuilder/src/logger.hpp@
aab470
| Last change on this file since aab470 was c3f8c4, checked in by , 16 years ago | |
|---|---|
|
|
| File size: 752 bytes | |
| Line | |
|---|---|
| 1 | /* |
| 2 | * logger.hpp |
| 3 | * |
| 4 | * Created on: Oct 19, 2009 |
| 5 | * Author: metzler |
| 6 | */ |
| 7 | |
| 8 | #ifndef LOGGER_HPP_ |
| 9 | #define LOGGER_HPP_ |
| 10 | |
| 11 | #include <iostream> |
| 12 | |
| 13 | #include "Patterns/Singleton.hpp" |
| 14 | |
| 15 | using namespace std; |
| 16 | |
| 17 | class Verbose; |
| 18 | |
| 19 | class logger : public Singleton<logger> { |
| 20 | friend class Singleton<logger>; |
| 21 | public : |
| 22 | static ostream *nix; |
| 23 | static int verbosity; |
| 24 | |
| 25 | static bool DoOutput(); |
| 26 | static void setVerbosity(int verbosityLevel); |
| 27 | |
| 28 | protected: |
| 29 | /** Do not call this constructor directly, use getInstance() instead. */ |
| 30 | logger(); |
| 31 | /** Do not call this destructor directly, use purgeInstance() instead. */ |
| 32 | ~logger(); |
| 33 | }; |
| 34 | |
| 35 | ostream& operator<<(class logger&l, const Verbose& ost); |
| 36 | ostream& operator<<(class logger*l, const Verbose& ost); |
| 37 | |
| 38 | #endif /* LOGGER_HPP_ */ |
Note:
See TracBrowser
for help on using the repository browser.
