[TYPO3-ect] Registry-Pattern for lib/div?

Joerg Schoppet joerg at schoppet.de
Thu Aug 16 08:59:26 CEST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Christian Welzel wrote:
> This is a problem of PHP4 which does per default always copy objects on
> assignments. The solution would be either to drop PHP4 support, and get
> rid of the copying with PHP5 (which assigns objects always per reference)
> or to mark all necessary places with a reference operator
> [ function controller(&$controller) { $this->controller = &$controller; } ].
The registry-pattern should not resolve the problem between
assign-by-value and assign-by-reference.
A lot of different objects in the lib-source need access to the actual
controller-, configuration- and parameter-object and assigning these
objects again and again, doesn't matter if by-value or by-reference, is
in my opinion a consideration to use the registry-pattern.

Joerg

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGw/XOq5Me6rRDqPURAp7LAJ9ylfNKqhgWC0Ouei4eXgVSLrNgDwCgi8nW
pXC7sHzVOSSH7IuUro4nEw4=
=F3hA
-----END PGP SIGNATURE-----


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