00001 /* Copyright (c) 2007, Gennady Bystritsky <bystr@mac.com> 00002 * 00003 * Distributed under the MIT Licence. 00004 * This is free software. See 'LICENSE' for details. 00005 * You must read and accept the license prior to use. 00006 */ 00007 00008 #ifndef _SK_RT_LOGGER_ICONFIG_ 00009 #define _SK_RT_LOGGER_ICONFIG_ 00010 00011 #include <sk/util/Object.h> 00012 #include <sk/rt/logger/Destination.h> 00013 #include <ostream> 00014 00015 namespace sk { 00016 namespace rt { 00017 namespace logger { 00018 class Level; 00019 00020 class IConfig 00021 : public virtual sk::util::Object 00022 { 00023 public: 00024 virtual bool checkLogLevel(const Level& level) const = 0; 00025 virtual logger::Destination& getLogDestination() const = 0; 00026 virtual const char* getTimeFormat() const = 0; 00027 virtual bool isLogPid() const = 0; 00028 virtual bool isLogTime() const = 0; 00029 virtual bool isLogObject() const = 0; 00030 00031 virtual void setLogDestination(const logger::Destination& destination) = 0; 00032 virtual void setLogLevel(const logger::Level& level) = 0; 00033 virtual void setTimeFormat(const sk::util::String& format) = 0; 00034 virtual void setLogPid(bool state) = 0; 00035 virtual void setLogTime(bool state) = 0; 00036 virtual void setLogObject(bool state) = 0; 00037 }; 00038 } 00039 } 00040 } 00041 00042 #endif /* _SK_RT_LOGGER_ICONFIG_ */