There is a suching extension to handle (intercepts) implicit (or no)
reference.
Ex.:
$a = new A():
$b = $a;
I want something like __clone(), something like __reference() to be invoked
in the second line of the given example.
Thanks.
--
Mathias Grimm
Hi Mathias,
There is a suching extension to handle (intercepts) implicit (or no)
reference.Ex.:
$a = new A():
$b = $a;I want something like __clone(), something like __reference() to be invoked
in the second line of the given example.
Do you have a usecase?
Best regards.
--
Ivan Enderlin
Developer of Hoa
http://hoa.42/ or http://hoa-project.net/
PhD. student at DISC/Femto-ST (Vesontio) and INRIA (Cassis)
http://disc.univ-fcomte.fr/ and http://www.inria.fr/
Member of HTML and WebApps Working Group of W3C
http://w3.org/
Hi,
I had a possible use case while working with an application registry. Any
model could "get a copy" of it to read application settings or retrieve a
resource. However if a model by mistake changed a property, it would
modify the original object without going through proper setters... A quick
solution was to use "clone" whenever returning the registry.
Best regards
On 10 May 2012 21:34, Ivan Enderlin @ Hoa ivan.enderlin@hoa-project.netwrote:
Hi Mathias,
There is a suching extension to handle (intercepts) implicit (or no)
reference.Ex.:
$a = new A():
$b = $a;I want something like __clone(), something like __reference() to be
invoked
in the second line of the given example.Do you have a usecase?
Best regards.
--
Ivan Enderlin
Developer of Hoa
http://hoa.42/ or http://hoa-project.net/PhD. student at DISC/Femto-ST (Vesontio) and INRIA (Cassis)
http://disc.univ-fcomte.fr/ and http://www.inria.fr/Member of HTML and WebApps Working Group of W3C
http://w3.org/