Tom Mueller wrote:
> Shawn Walker wrote:
>>> line 96: why doesn't clear() clear the image dir? Is this to allow 
>>> multiple operations on a single image to happen? What happens if a 
>>> process has multiple image objects, and it flips back and forth 
>>> between operations on them?
>> history.py
>>
>> The client needs to call set_imgdir any time it changes image 
>> directory context.  As far as I'm aware, both of our clients are 
>> limited to a single image for a given session.  So, I didn't think it 
>> was a problem for now.  Once we have a client API, this can be 
>> centralised so it shouldn't be an issue long-term either.
>>
> The more I think about it, it seems that the history should be an 
> attribute of the Image object, especially since the history is stored 
> within the Image meta data. There is no need for Image to be an object 
> if history is not. This seems to break the object-oriented design of the 
> rest of the system.

I didn't feel the need to tie the history object to the image object in 
that way.

As for object-oriented -- we seem to have a hybrid approach rather than 
a pure one.

> I did check on the updatetool GUI and it too does not create multiple 
> Image objects and keep them around.  However, since it is oriented 
> towards managing user images, it does present the user with multiple 
> images, and a very natural implementation would seem to be to create 
> multiple Image objects and keep them around for the life of the session.

As I said before, long-term, a client API will solve a lot of the issues 
around this since I can the current hooks in better places.

-- 
Shawn Walker
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to