Re: No Namespaces & Vortex

Manuel Holtgrewe <[email protected]>
Newsgroups gmane.comp.lib.binarycloud.devel
Message-ID <[email protected]>
Jean-Christophe Michel schrieb:
> Manuel Holtgrewe wrote:
> 
>> Hi
>>
>> Since there are no namespaces in PHP we will soon hit a problem with 
>> duplicate class names (Item is something widely used, I believe). I 
>> think we should add a rule that class names have to be prefixed with 
>> the package's name, i.e: StoreItem, MyAppItem, FooItem.
>>
>> Other ideas/thoughts?
> 
> 
> Leads to huge names. We should have a naming convention.
> And I propose to use the fact that php authorize any char [128-255] in 
> var names to choose one as namespace separator: can be trema ¨, tilde ~, 
> mdash —, midpoint ·, or some else easily accessible from all keyboards.
> 
> Examples:
>    store¨Item
>    store~Item
>    store—Item
>    store·Item
> 
> I personnally like the midpoint.

Or we go to PEAR conventionsand take the underscore:

Binarycloud_Node

etc.


Manuel
_______________________________________________
dev mailing list
dev-PnctHDZWAvB/Cz2I37pSEPZ4XP/[email protected]
http://lists.binarycloud.com/mailman/listinfo/dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.