In any event, there's an alternative to using the Singleton:
$registry = new Zend_Registry();
And then? If I need to fetch a data from registry, I should create new
registry object each time? I don't understand how you would use it, can
you give an example of get and put use case?
If they're not using MVC, then there's any number of ways they may be
handling passing this object. We currently have no Zend_Controller_Page
class--that could make it more evident how to handle situations like this.
Of course there's the number of ways to pass it - just I don't see why
should they pass it at all. We had perfectly working simple interface
and methods that did not require that and now you want to break it and
have user to invent "number of ways" - what for?
In that case, we need to go back to the drawing board with components that
model "simple" processes like Zend_Session (Zend_Session_Namespace adds
value, but is not intuitive) or the new Zend_Log class (passing a
Zend_Log_Writer_* object to the constructor could be confusing).
I don't know about Zend_Log, didn't look at it sufficiently to make mind
about it. I am just very concerned about the tendency of taking very
simple basic interfaces and over-design them into complex set of methods
and concepts that in 90% of use cases are not needed at all.
I understand what you're saying, and agree to a point; I think it's
reasonable to try to accommodate users in terms of ease of use. But I
I don't think it's just "reasonable". I think it's the priority we
should take, otherwise we'd end up designing Java.
think it's equally reasonable to require a little effort on their part, as
well.
As little as possible. If there's a way not to require the effort, that
is the way we should take.
--
Stanislav Malyshev, Zend Products Engineer
[EMAIL PROTECTED] http://www.zend.com/