Re: true namespaces, yet another point of view
| From: | Lupus Michaelis | Date: | Wed, 24 Sep 2008 07:43:35 +0000 |
| Subject: | Re: true namespaces, yet another point of view | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-40659@lists.php.net to get a copy of this message | ||
Arvids Godjuks a écrit :
Of course that isn't a good example, because Zend framework always has a class prefix "Zend", but they surely can use a namespace and remove that Zend in front of classes.They are a lot of case where you want to use this syntax. The most common is when you have a depth namespace like a russian puppy : namespace org::w3::xhtml::strict as x ; The other reason is to use it for testing purposes, when you develop a new engine, that share the same API with the previous : // namespace org::w3::xml as xml ; namespace com::lupusmic::xml as xml ; But maybe it isn't a good use... :D Namespaces can be a usefull tool, but if wouldn't, don't use. And if it becomes mandatory, fork your own PHP version :D -- Mickaël Wolff aka Lupus Michaelis http://lupusmic.org