← Back to team overview

launchpad-dev team mailing list archive

Re: API issue moving branches

 

On Wed, May 12, 2010 at 08:55:51AM +0100, Julian Edwards wrote:
> On Monday 10 May 2010 11:39:24 Leonard Richardson wrote:
> > I take Francis's general point that we should think about the API that
> > will feel most natural to the end-user, rather than publishing our
> > internal API directly.
> 
> I find this quite hard to do since the API exposes our model objects.

So, does our interal model API feel natural to us, but not to our users? I
doubt it. If our model API isn't good, we should take the opportunity to
improve it. When Francis said that distribution and product attributes
are implementation details, I'd interpret that as they are *storage*
implementation details.

Even our internal API shouldn't expose those
attributes as being writable. These should be written only inside the
model object itself. If something outside the model object sets it, it
should use the target attribute/method, which takes care of all the
logic.


-- 
Björn Tillenius | https://launchpad.net/~bjornt



Follow ups

References