By the way ...
I personally isolate the call to Logger.getLogger(
String or Class) in to a static method in a helper class HelperLogger.getLogger() that does not take any argument.
In this method I use the Thread.currentThread().getStackTrace() that returns a StackTraceElement array. Using the StackTraceElement.getClassName() I retrieve the String to be passed to the Logger.getLogger(String) of Log4J.
The main advantage is that you can now cut&paste you LoggerHelper.getLogger() statements in all your classes without having to modify them.
Nicolas
[ May 29, 2008: Message edited by: Nicolas Brasseur ]
[ May 29, 2008: Message edited by: Nicolas Brasseur ]