[PATCH][MERGE] Improvements to is_ignored, take 2

Jan Hudec bulb at ucw.cz
Sat Jan 14 22:10:05 GMT 2006


On Sat, Jan 14, 2006 at 22:53:08 +0100, Denys Duchier wrote:
> Jan Hudec <bulb at ucw.cz> writes:
> 
> > Anyway, the question is how the two objects, Session and
> > Branch/WorkingTree/whatever should be related. Should we call methods on the
> > object and give all the methods a Session?
> 
> No they should all be created _in_ a session (i.e. through invoking a method of
> the session).

So we actually say that Branch, WorkingTree and should only be created for
a session, right? Well, we certainly could, though I am not sure it's exactly
pleasant for the frontends. 

The thing I have in mind is this: Consider the fronted that operates on
a bunch of files in a working tree. Perhaps they are open in editor and user
currently works on them. The frontend needs to keep something it can use to
get status, diff, start commit and such around for each of them. In other
words would have a tendency to keep an open WorkingTree instance referenced
from it's objects representing those files.

> > But what about threads? Every thread should have it's own Session, but they
> > certainly don't want their own Branch and WorkingTree objects...
> 
> and why not, je vous prie?

A better question would be 'should they have to?'.

Anyway, logically it sounds wrong. Branch and working tree are the things
that are, so the objects should be long-lived, logically. While session is
the short-lived thing.

-- 
						 Jan 'Bulb' Hudec <bulb at ucw.cz>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060114/d7556091/attachment.pgp 


More information about the bazaar mailing list