1) Everything accessed via the Registry, 2) there is a separate class that holds/calculates the paths and names for Actions, etc. to use (so no dependency on the FC object at all), and 3) the Registry object is injected into Action constructors/methods so no static calls required. It makes it lighter and everything replaceable, but that is it own set of design trade-offs -- hence the arguments about the lack of concrete interfaces, etc. You just can't win design discussions.Theory? wrote:How does Skeleton handle it by default?
Zend front controller and getInstance()
Moderator: General Moderators
- Christopher
- Site Administrator
- Posts: 13596
- Joined: Wed Aug 25, 2004 7:54 pm
- Location: New York, NY, US
Re: Zend front controller and getInstance()
(#10850)
Re: Zend front controller and getInstance()
Exactly, I could argue that its so simple to replace the static call in the ZF context with an object registry, its the temptation static calls gives you to design bad that is the danger, you've just gone out of your way to do what most are too lazy to do. Even so the FC should still be a singleton, not a Singleton tho ( or the other way around, you get my point ). http://www.thekua.com/atwork/2009/01/si ... -instance/ sums it up conciselyarborint wrote:. You just can't win design discussions.