-------- Původní zpráva --------
Předmět: Re:Namespace resolution rules has been changed?
Od: David Grudl <[EMAIL PROTECTED]>
Datum: 10.11.2008 23:53
> Can you please point us to an example describing this best practice?

For example Namespace Naming Guidelines in .NET (http://msdn.microsoft.com/en-us/library/893ke618(VS.71).aspx)

"A nested namespace should have a dependency on types in the containing namespace. For example, the classes in the System.Web.UI.Design depend on the classes in System.Web.UI. However, the classes in System.Web.UI do not depend on the classes in System.Web.UI.Design."

Or Zend Framework source code. There is no class extending class from subpackage (class Zend_View extends Zend_View_Abstract is not subpackage, viz http://framework.zend.com/wiki/display/ZFPROP/Naming+conventions+for+2.0+-+Matthew+Ratzloff).
*
*

And another example is Nette Framework, maybe the first PHP framework ready to use namespaces. Nowhere in the code is the place where "relative qualification" would be useful. On the contrary, in all places you is needed "full qualifications". Obligation to use the slash is just a pain.

DG.

Reply via email to