[xwiki-dev] Re: [ArchitectureV2] Model proposal

Catalin Hritcu catalin.hritcu at gmail.com
Thu May 31 19:17:57 CEST 2007


Hi,

On 5/30/07, Sergiu Dumitriu <sergiu.dumitriu at gmail.com> wrote:
> On 5/29/07, Vincent Massol <vincent at massol.net> wrote:
> > Some more details on this topic:
> >
> > * We should have a consistent naming. Either we use XObjects/XClass
> > and then we have to use X in front of everything: XFarm, XWiki
> > (funny), XSpace, XDocument, etc or we agree that the namespace is
> > enough (org.xwiki.model) to indicate that these are all XWiki classes
> > and we drop the X. This is my preference. When we write documentation
> > we can refer to XObjects/XClass/ to separate them from Java Objects/
> > Class though.
> >
>
> I'm for the second option, with the minor objection that I don't like
> having an Object class. Name collision with the most used class in the
> Java world. But I can deal with this inconvenience.
>

Sorry if I seem picky about a naming issue, but I think that naming
any class Class or Object is _extremely_ confusing, not only in the
discussions but also when reading code.  One of the many reasons is
that the java.lang package doesn't need to be imported explicitly. We
already had a proposal we accepted to call them XClass and XObject:
http://mail-archive.objectweb.org/xwiki-dev/2007-04/msg00073.html

I think that naming consistency should not come at the expense of
clarity. And if you still want naming consistency then I suggest
calling them MetaClass and MetaObject, instead of perpending all the
other concepts by an "X".

Regards,
Catalin




More information about the devs mailing list