NYCPHP Meetup

NYPHP.org

[nycphp-talk] PHP 5 singleton/destructor question

Daniel J Cain Jr. dan at cain.sh
Fri Apr 1 02:25:35 EST 2005


Actually calling a static method will call a constructor if that method 
creates an object of itself.  And a static call that removes the last 
reference to the object in the script will also call that objects 
destructor.

Jeff Loiselle wrote:
> Constructors and destructors are not executed when you call static
> methods of a class. Calling a method statically, doesn't make a class.
> ;-) I think I read that in George's book. Hope that helps.
> _______________________________________________
> New York PHP Talk Mailing List
> AMP Technology
> Supporting Apache, MySQL and PHP
> http://lists.nyphp.org/mailman/listinfo/talk
> http://www.nyphp.org



More information about the talk mailing list