2008/10/22 Ryan Panning <[EMAIL PROTECTED]>:
> I've been wondering, is such a thing even possible? Is there a good way to
> implement an object destruct order? Here are my thoughts:
>
> In the class definition, specify what "level" of destruction the objects
> should be on. How, I have no idea, I h
I think this should be implemented by user. If you are full OOP in your
application, then just register all your objects in some global object (In
my case I have a global singelton) and trigger hiv removal at the end of
your application. If you have destructors written in every object - they
will b
Jani Taskinen wrote:
Nathan Rixham wrote:
just to add it in; in ejb3 in java you have PostConstruct and
PreDestroy which are pretty useful; maybe something along the same
lines could be implemented in PHP?
Or perhaps you should just stick with Java?
just a suggestion for some useful func
Nathan Rixham wrote:
Diogo Galvão wrote:
"The destructor method will be called as soon as all references to a
particular object are removed or when the object is explicitly destroyed
or in any order in shutdown sequence."
As far as I understand it if your active record references the PDO
instan
Diogo Galvão wrote:
"The destructor method will be called as soon as all references to a
particular object are removed or when the object is explicitly destroyed
or in any order in shutdown sequence."
As far as I understand it if your active record references the PDO
instance (say $this->conn) y
"The destructor method will be called as soon as all references to a
particular object are removed or when the object is explicitly destroyed
or in any order in shutdown sequence."
As far as I understand it if your active record references the PDO
instance (say $this->conn) your object gets destr
Hello Ryan,
during 5.0 alpha phase I had that actually implemented. But it turned
out to be too much of a slowdown and also could not solve all dependency
graphs. For example you can obviously not solve dependency cycles. So at
the end of the experiement we decided against it.
Maybe we could im
I believe the "end of your script" part is the problem. Imagine you
have some
object (say, ActiveRecord style) that writes itself to the database
when it's
destroyed if the data has been modified. Now cache that object in a
static
variable somewhere for performance. You're also using PDO,
On Wednesday 22 October 2008 2:31:38 am Mike van Riel wrote:
> >> Example destruction order:
> >> 3 = database records (ActiveRecord or such)
> >> 2 = database connection object
> >> 1 = framework objects
> >> 0 = objects with unspecified level
> >
> > Why would you need such thing?
> > PHP uses r
Hi,
Naturally this line:
"$this->addObject($this, $priority);"
was meant to be:
$destructManager->addObject($this, $priority);" ...
Regards,
Stan Vassilev
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
On Wed, Oct 22, 2008 at 5:03 AM, Ryan Panning <[EMAIL PROTECTED]> wrote:
I've been wondering, is such a thing even possible? Is there a good way
to
implement an object destruct order? Here are my thoughts:
In the class definition, specify what "level" of destruction the objects
should be on. Ho
Alexey Zakhlestin wrote:
On Wed, Oct 22, 2008 at 5:03 AM, Ryan Panning <[EMAIL PROTECTED]> wrote:
I've been wondering, is such a thing even possible? Is there a good way to
implement an object destruct order? Here are my thoughts:
In the class definition, specify what "level" of destruction the
On Wed, Oct 22, 2008 at 5:03 AM, Ryan Panning <[EMAIL PROTECTED]> wrote:
> I've been wondering, is such a thing even possible? Is there a good way to
> implement an object destruct order? Here are my thoughts:
>
> In the class definition, specify what "level" of destruction the objects
> should be
13 matches
Mail list logo