Re: How can I do this -- method chaining

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Jan 30, 2008 10:46 AM, Stut <stuttle@xxxxxxxxx> wrote:

> Nathan Nobbe wrote:
>
> Actually no, I mean I would *just* use a static method. If there is no
> reason to instantiate an object, why would you? <http://stut.net/>


you realize you are instantiating an class in the code you posted, right?
from you post:
$o = new Test();
if i didnt know any better, id call that an instantiation of the Test class
;)
the only thing is you are forcing it out of scope by using a local variable
to store the reference to the object.

-nathan

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux