I followed all the examples that i have (included the 1.2 beta 4) and none can geve me the answer. My main problen is a ClassCastException and I can't fix it.
Raśl. -----Original Message----- From: Ribot Jaume (EXT-Nokia/Barcelona) Sent: 03 mayo, 2002 10:45 To: [EMAIL PROTECTED] Subject: RE: xml configuration problem (i forgot the xml file) See the examples available with version 1.2 beta 4, you can find how to do it there. See how to instantiate the logger in the example MyLoggerTest Que lo sepas! Jaume -----Original Message----- From: Viloria-Santos Raul (EXT-UPC/Barcelona) Sent: 03. May 2002 10:17 To: [EMAIL PROTECTED] Subject: RE: xml configuration problem (i forgot the xml file) Hi all, I'm using log4j1.1.3 and I'm trying to make a subclass to the Category class to log a different message, just to add something to the message. I made MyCategory class quite similar to the example given and I made MyCategoryFactory as well, but when I instantiate it in the main program it gives me an error message (ClassCastException) if the class name matches the category name in my .xml config file. What should I do?. It only works if it doesn't match any category. Then it uses the root part of the .xml file and not the category part that I want. I've read somewhere that i must set the factory in the config file, then I ask: How do I set the category in a .xml file? Should I put MyCategory instead of Category in my .xml configuration file? Do I need to put some extra things in my main code or in my .xml file? This is my .xml file: <category name="helloworld.hw_log" additivity="false"> <priority value="error"/> <appender-ref ref="JDBC" /> </category> <root> <priority value="fatal"/> <appender-ref ref="SYSTEMOUT" /> </root> Thank you all. Raśl -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>