Re: use of static methods after namespaces arrive
| From: | Adam Richardson | Date: | Wed, 28 May 2008 15:55:48 +0000 |
| Subject: | Re: use of static methods after namespaces arrive | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-274772@lists.php.net to get a copy of this message | ||
If the functionality doesn't conceptually promote the inclusion of the
variables it works on (i.e., no class variables), doesn't conceptually fit a
scheme where instances can exist, and likely won't benefit from refactoring
into component methods, then I could see using a namespaced function.
Most of the time, though, I'd probably start out with a class method instead
of a namespaced function so I could more readily adapt to OOP practices if
desired as the implementation evolves.
Adam
On Wed, May 28, 2008 at 11:33 AM, Iv Ray <pobox@verysmall.org> wrote:
> In which situation would somebody use a static method, instead of a
> function in a namespace, after the namespaces arrive with 5.3?
>
> Iv
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>