[Zope3-dev] DISCUSS: getting rid of the obscure "Title" convention

Martijn Faassen faassen@vet.uu.nl
Thu, 13 Dec 2001 00:08:00 +0100


Lalo Martins wrote:
> at: http://dev.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/SecurityFramework
> 
> > Interface IPrincipal
> >  getTitle()
> >    Return a label for the principal
> 
> So, why is it getTitle() and not getLabel()?
> 
> The use of the Title property/method is an obscure convention in Zope2
> and, in most places, a misnomer.

I agree getLabel() would be a better name for this method. While titles
are frequently indeed used to fill <title> </title> in HTML pages,
they're also frequently used for other purposes, such as in 
tables of contents of objects, or indeed as a label in Formulator fields
(though I'm to 'blame' for the latter :).

So calling them labels sounds like a good idea.

Regards,

Martijn