[ZODB-Dev] experimenting with Standalone ZODB...

Christian Robottom Reis kiko@async.com.br
Fri, 26 Oct 2001 11:54:11 -0200 (BRST)


On Mon, 22 Oct 2001, Michel Pelletier wrote:

> I agree, although how the interface is exposed will be an issue. 
> Currently the persistence of an object is exposed through _p_
> attributes, would this be extended?  I think that's fine, altough to

Possibly have a list of revisions stored as _p_revisions, indexed by
revision number. This might be a hash if the number of revisions isn't
strictly a list.

> start, I would just expose another module in ZODB that provided methods
> you pass a persistent object too::
> 
> from ZODB import History
> 
> History.getRevision(object, 0)  # current, same as 'object'
> History.getRevision(object, 1)  # previous revision
> etc...

This, as you point out, is a pretty good compromise :) 

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 272 3330 | NMFL