-------- Original Message --------
Subject: Re: [logging] To depend or not to depend?
Date: Sat, 8 Feb 2003 18:09:16 -0000
From: James Strachan <[EMAIL PROTECTED]>
Reply-To: Jakarta Commons Developers List <[EMAIL PROTECTED]>
Newsgroups: gmane.comp.jakarta.commons.devel
References: <[EMAIL PROTECTED]> <b21lsb$v3d$[EMAIL PROTECTED]> <b23f1e$b9r$[EMAIL PROTECTED]>
From: "Leo Simons" <[EMAIL PROTECTED]>
Leo Simons wrote: > What is probably perfectly doable is providing: > -------------------------------- > package org.apache.avalon.framework; > > public class CommonsLoggingLogger implements Logger <snip/> > -------------------------------- > > this is on the TODO. Not for an upcoming avalon-framework 4.1.4, but it > might very well be in 4.1.5.okay, so I took a closer look and just implemented this as it's real easy to do. I actually did public final class CommonsLogger implements Logger, Log { /* ... */ } as that makes life even easier on component developers. One method causes problems: interface Logger { /** * Create a new child logger. * The name of the child logger is [current-loggers-name].[passed-in-name] * Throws <code>IllegalArgumentException</code> if name has an empty element name * * @param name the subname of this logger * @return the new logger */ Logger getChildLogger( String name ); } as [current-loggers-name] is not exposed by Log. Would it be acceptable to add a getName() or something similar to the Log interface and the implementations? That way, we can fully implement the avalon-framework Logger contract on top of commons-logging.
+1. Seems reasonable to me. I guess it won't break anyones code who just use commons-logging to log. The only risk is people who implement Log, but since most of the implementations are inside commons-logging, it doesn't seem too bad. BTW did you mean to CC [EMAIL PROTECTED] or did you mean avalon-dev? :) --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
