-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi,
robert burrell donkin wrote: > On Fri, 2005-08-05 at 13:44 +0200, Ceki Gülcü wrote: > > <snip> > >>The first method, namely getName(), sounds most legitimate. If the >>developer retrieves loggers by name, it is only natural for those >>loggers to have a name. The only exception is the NOPLogger >>singleton. If SLF4J is bound to the NOP implementation, the logger >>factory will always hand the user the same NOPLogger instance, >>regardless of the name of the logger requested by her. >> >>Thus, it seems quite reasonable to add the getName() method, with the >>caveat that the name you get may be different than the name you asked >>for. :-) > > > +1 > > would null be a legitimate return value? In my oppinion not. There might be a "root-logger" instance that have a zero-length name (empty string). But each other logger should have a meanfull name. That name might be "org.slf4j.NOPLogger" and might not match the name set on creation what should usually be the case. A regular name for a logger is the classpath of the component/class that owns/uses the logger. The implementation should accept any string as name, but the javadoc should specify this more precisely (e.g. only 'a'-'Z','0'-'9','.','-' should be used and so on). > > - robert Jörg -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFC99Z4mPuec2Dcv/8RAmwCAJ4uCXJd6OvPX5h+3smMctfMbKFyEQCeOgdt +R7P8SaQRsFBWXxBusflKMs= =+sCW -----END PGP SIGNATURE----- _______________________________________________ dev mailing list [email protected] http://slf4j.org/mailman/listinfo/dev
