tag:blogger.com,1999:blog-36547168.post358698621003647874..comments2023-11-25T11:00:42.257+01:00Comments on Invisible to the eye: Practical Php Patterns: Abstract FactoryGiorgiohttp://www.blogger.com/profile/03558287012747987157noreply@blogger.comBlogger9125tag:blogger.com,1999:blog-36547168.post-88461074630905268542015-02-04T18:26:06.178+01:002015-02-04T18:26:06.178+01:00Did you mean private $_widgetFactory; to actually...Did you mean <i> private $_widgetFactory;</i> to actually be <i> private $_widgetHelperFactory;</i> as the first is never used and the second is used but never instantiated.Unknownhttps://www.blogger.com/profile/05322590937910431311noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-80947278959326310722010-02-17T22:13:58.965+01:002010-02-17T22:13:58.965+01:00Yes, an higher level factory will create the contr...Yes, an higher level factory will create the controller and inject the lower level factory it needs to perform its work.Giorgiohttps://www.blogger.com/profile/12689416577856305650noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-1673217100446405592010-02-17T21:43:45.256+01:002010-02-17T21:43:45.256+01:00If I need to decide at runtime which factory to cr...If I need to decide at runtime which factory to create, what will be the best approach, do I have to inject this decision maker in my controller?Unknownhttps://www.blogger.com/profile/16555661418154584127noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-60520604395345792852010-01-14T20:15:22.477+01:002010-01-14T20:15:22.477+01:00Your print stylesheet breaks on Firefox on Ubuntu....Your print stylesheet breaks on Firefox on Ubuntu. There is one page of text then the menu and that's it.<br /><br />Bummer for printing to read later.jakyrahttps://www.blogger.com/profile/01826813470235427187noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-67065446744171674752010-01-12T00:38:31.196+01:002010-01-12T00:38:31.196+01:00Nice article, waiting to read the next one in the ...Nice article, waiting to read the next one in the series!Jonathan Nietohttps://www.blogger.com/profile/01878987006966757870noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-76693046495518992982010-01-07T20:16:21.867+01:002010-01-07T20:16:21.867+01:00Currently the architecture does not permit to inje...Currently the architecture does not permit to inject anything in controllers; what can you do is instantiating a factory in a bootstrap resource. It is often cleaner to inject directly the dependencies (but since the controllers should have an empty-argument constructor a factory is the only choice).Giorgiohttps://www.blogger.com/profile/12689416577856305650noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-10948034029862386782010-01-07T19:44:57.019+01:002010-01-07T19:44:57.019+01:00Very nice, do you also use this technique to injec...Very nice, do you also use this technique to inject dependencies in zf action controllers? If so how do you inject the abstract factory? And is it clean to use an abstract factory to create different (unrelated) objects just for the sake of providing the client with dependencies.Unknownhttps://www.blogger.com/profile/16555661418154584127noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-81135588588064586022010-01-07T17:50:03.965+01:002010-01-07T17:50:03.965+01:00I just kept the GoF terminology: the name illustra...I just kept the GoF terminology: the name illustrates that Client depends only on abstractions. :)Giorgiohttps://www.blogger.com/profile/12689416577856305650noreply@blogger.comtag:blogger.com,1999:blog-36547168.post-38578307801857488602010-01-07T13:43:09.058+01:002010-01-07T13:43:09.058+01:00Good start. Curious about the things to come.
The...Good start. Curious about the things to come.<br /><br />The word "Abstract" in the interface classnames could be a bit confusing since it's often used in abstract classes. Maybe a short note clarifying this would be helpful (especially for novice readers).Janhttp://sorgalla.comnoreply@blogger.com