Package org.apache.log4j.config
Class PropertyPrinter
java.lang.Object
org.apache.log4j.config.PropertyPrinter
- All Implemented Interfaces:
PropertyGetter.PropertyCallback
Prints the configuration of the log4j default hierarchy (which needs to be auto-initialized) as a propoperties file
on a
PrintWriter.- Author:
- Anders Kristensen
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Hashtableprotected booleanprotected Hashtableprotected intprotected PrintWriter -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Stringcapitalize(String name) voidfoundProperty(Object obj, String prefix, String name, Object value) protected Stringprotected booleanisGenAppName(String name) Returns true if the specified appender name is considered to have been generated, that is, if it is of the form A[0-9]+.static voidvoidprint(PrintWriter out) Prints the configuration of the default log4j hierarchy as a Java properties file on the specified Writer.protected voidprintOptions(PrintWriter out, Object obj, String fullname) protected voidprintOptions(PrintWriter out, Category cat) protected voidprintOptions(PrintWriter out, Logger cat)
-
Field Details
-
numAppenders
protected int numAppenders -
appenderNames
-
layoutNames
-
out
-
doCapitalize
protected boolean doCapitalize
-
-
Constructor Details
-
PropertyPrinter
-
PropertyPrinter
-
-
Method Details
-
genAppName
-
isGenAppName
Returns true if the specified appender name is considered to have been generated, that is, if it is of the form A[0-9]+. -
print
Prints the configuration of the default log4j hierarchy as a Java properties file on the specified Writer.N.B. print() can be invoked only once!
-
printOptions
- Since:
- 1.2.15
-
printOptions
-
printOptions
-
foundProperty
- Specified by:
foundPropertyin interfacePropertyGetter.PropertyCallback
-
capitalize
-
main
-