Peter Donald wrote:
> 
> >
> > Hmmm, I'm not sure if this is a good feature - because an optional
> > dependency means it's - well - optional. And I see two use cases
> > their:
> > a) The optional component is only used if it is available
> 
> thats the usecase I had in mind.
> 
> > b) The optional component is used only in some circumstances
> 
> That is the usecase that I originally liked but Berin jumped on 
> me back in ye 
> old days for it. Then we both jumped on Fede (one of the original avalon 
> developers).
> 
> Whats everyone else think. Should optional dependencies be "optional" 
> depending on the presence of some attribute (be it config variable or 
> something). 
> 
> Or should it be the assemblers decision, ie If they provide the 
> component then 
> it is used else it is not.
> 
I think the XSLTProcessor is a good example for a use-case of b).

A store is available in (nearly) every system, so this component is
always present. If we only have use-case a), then the XSLTProcessor
always uses the store for caching stylesheets. 
That would be a realy problem if you have many, changing stylesheets.
The caching would reduce performance.

So, I think b) is needed - unless we want to XSLTProcessors (
a caching and a non-caching one)...


Carsten

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

Reply via email to