PropertyConfiguratorImpl.hh
Go to the documentation of this file.
00001 /*
00002  * PropertyConiguratorImpl.hh
00003  *
00004  * Copyright 2002, Log4cpp Project. All rights reserved.
00005  *
00006  * See the COPYING file for the terms of usage and distribution.
00007  */
00008 
00009 #ifndef _LOG4CPP_PROPERTYCONFIGURATORIMPL_HH
00010 #define _LOG4CPP_PROPERTYCONFIGURATORIMPL_HH
00011 
00012 #include "PortabilityImpl.hh"
00013 #include <log4cpp/Configurator.hh>
00014 #include <log4cpp/Appender.hh>
00015 #include <log4cpp/Category.hh>
00016 #include <string>
00017 #include <iostream>
00018 #include <map>
00019 #include <vector>
00020 
00021 #include "Properties.hh"
00022 
00023 namespace log4cpp {
00024     
00025     class PropertyConfiguratorImpl {
00026         public:
00027         typedef std::map<std::string, Appender*> AppenderMap;
00028 
00029         PropertyConfiguratorImpl();
00030         virtual ~PropertyConfiguratorImpl();
00031         virtual void doConfigure(const std::string& initFileName)
00032             throw (ConfigureFailure);
00033         virtual void doConfigure(std::istream& in)
00034             throw (ConfigureFailure);
00035 
00036         protected:
00045         void configureCategory(const std::string& categoryname) throw (ConfigureFailure);
00046 
00052         void getCategories(std::vector<std::string>& categories) const;
00053 
00054         void instantiateAllAppenders() throw(ConfigureFailure);
00055 
00069         Appender* instantiateAppender(const std::string& name);
00070 
00077         void setLayout(Appender* appender, const std::string& name);
00078 
00079         Properties _properties;
00080         AppenderMap _allAppenders;
00081     };
00082 }
00083 
00084 #endif // _LOG4CPP_PROPERTIES_HH
00085 


log4cpp
Author(s): Stephen Roderick
autogenerated on Mon Oct 6 2014 03:13:14