Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

log4cpp::PropertyConfigurator Class Reference

Property configurator will read a config file using the same (or similar) format to the config file used by log4j. More...

#include <PropertyConfigurator.hh>

List of all members.

Static Public Methods

void configure (const std::string &initFileName) throw (ConfigureFailure)


Detailed Description

Property configurator will read a config file using the same (or similar) format to the config file used by log4j.

This file is in a standard Java "properties" file format.

Example:

       # a simple test config

       log4j.rootCategory=DEBUG, rootAppender
       log4j.category.sub1=A1
       log4j.category.sub2=INFO
       log4j.category.sub1.sub2=ERROR, A2
       
       log4j.appender.rootAppender=org.apache.log4j.ConsoleAppender
       log4j.appender.rootAppender.layout=org.apache.log4j.BasicLayout
       
       log4j.appender.A1=org.apache.log4j.FileAppender
       log4j.appender.A1.fileName=A1.log
       log4j.appender.A1.layout=org.apache.log4j.BasicLayout
       
       log4j.appender.A2=org.apache.log4j.ConsoleAppender
       log4j.appender.A2.layout=org.apache.log4j.PatternLayout
       log4j.appender.A2.layout.pattern=The message %m at time %d%n
       

Since:
0.3.2


Member Function Documentation

void log4cpp::PropertyConfigurator::configure const std::string &    initFileName throw (ConfigureFailure) [static]
 


The documentation for this class was generated from the following files:
Generated on Mon Oct 28 23:42:14 2002 for log4cpp by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002