Nomenclature
Gustavo Niemeyer
gustavo at niemeyer.net
Fri Sep 30 17:36:29 BST 2005
> I think Neimeyer's really asking "why does one have an underscore, but
> not the other"?
Precisely!
> My answer: revno is terminology used outside the code. I prefer
> underscores otherwise.
Well.. there are all kinds of terminologies out there. It'd be
nice if we could get consistent inside the core by sticking to
a given one we choose.
> >> * branch.get_revision_*() vs. branch.revision_*()
>
> The get_ operations tend to return complex objects, while non-prefixed
> ones tend to return strings, lists, etc.
Like get_rev_id() and get_parent()? :-)
> >> * branch.get_rev_id() vs. branch.revision_id_to_revno() vs. *.id2*()
>
> I think the question here is 'should or shouldn't we abbreviate "to" as
> "2"'?
Even if we don't, get_rev_id() and revision_id_to_revno() should
be fixed to be consistent with each other, given that they're
precisely the opposite of each other.
> >> * branch.controlfilename() and branch.controlfile() vs.
> >> branch.revision_history()
>
> These all make sense to me. controlfilename returns a path,
> controlfile returns a file, and revision_history produces information
> that may or may not have been obtained from a control file.
And why not control_filename() and control_file(), just like
revision_history()?
--
Gustavo Niemeyer
http://niemeyer.net
More information about the bazaar
mailing list