On Sunday, October 5, 2003, at 10:53 PM, Simon Kitching wrote:

<snip>

Hmm .. but calling Digester.setLogger probably doesn't override the
object known to the LogFactory...

What exactly is the purpose of being able to set the Log object used by
a class or instance?

so the instance used to log by digester can be set programmatically at runtime. this is a useful feature because:


1. it's a very convenient way to bypass the usual commons-logging configuration infrastructure. for example, it's often easier (when debugging) to setLogger programmatically on a particular instance than to reconfigure everything.

2. it allows digester to participate properly in frameworks based on inversion-of-control. (frameworks of this type are configured and controlled in a parent-child fashion. the Log to be used by a digester should be controlled by the component owning digester)

- robert


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to