[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cgiapp] A thank you note to Cees for CAP::LogDispatch


On Fri, 4 Feb 2005 09:49:54 -0500, William McKee <suppressed> wrote:
> Sounds interesting but I must confess that I don't see the benefit of
> using the plugin in non-C::A scripts over simply calling Log::Dispatch
> which already exports the logging functions.

The benefit I see is that the configuration and creation of the
Log::Dispatch object is in a central location.  With Rhesa's example,
you could use the following in any perl script:

use My::SimpleLog;
My::SimpleLog->log->debug('testing');

No configuration needed. as it is handled for you by the class.  That
is a whole lot easier than copying the configs from script to script. 
You could of course place the config in a central config object, but
then you are practically doing the same thing except you still need to
create the log object yourself in every script.

Cheers,

-- 
Cees Hek

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/suppressed/
              http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.