[TYPO3-ect] Spring and Symfony

Elmar Hinz elmar07 at googlemail.com
Thu Oct 4 09:44:23 CEST 2007


Hello,

I compared lib to Spring (JAVA) and to Sympfony (PHP)

Spring

The core idea of Spring is, to configure singletons and there relations by a
configuration file. It is an implementation of the injection pattern. It
simplifies unit testing. Objects can be quickly exchanged by changing the
configuration file without the need to recompile at all.

For JAVA objects that live persistantly in a container, it's a good idea to
instance them all in advance based on a configuration file. It's not useful
for an interpreted language like PHP. We only want to instance objects we
need on demand. 

To learn: Make all object relations configurable on the level of TS. 

Apart from this spring is a very flexible framework that can be combined
with other approches like XSLT, Struts, JSP etc. In this it is similar to
lib, wich also can combined with other libs on nearly every level.

Symfony

I mainly researched how the model is done, the DAO. It's Propel below. A
scaffold of the model is autogenerated based on an xml configuration file,
that describes the objects relations. The result is a model in traditional
style with a setter for each property: setId, setTitle, setName, .... 

After the quick startup by autogeneration the more work is awaiting because
of the setters. I think that's not really the road to go for lib/div,
taking your responses according this question into account. 

Different approaches are possible. We could use DAOs, that dynamically use
the TCA configuration instead of hardcoding all setters, wich is more
flexible than scaffolding.

Regards

Elmar


P.S. I am missing your reports of comparations with other frameworks!!! They
could give good advice.











































More information about the TYPO3-team-extension-coordination mailing list