[ZODB-Dev] FileStorage modification help - SOLVED
zope
zope@floSoft.net
Wed, 9 Apr 2003 18:14:09 +0200
On Tue, 8 Apr 2003 20:38:09 +0200
Dieter Maurer <dieter@handshake.de> wrote:
> fritz steindl wrote at 2003-4-7 18:03 +0200:
> > ...
> > ------------------------------------------------------------------
> > def store(self, oid, serial, data, version, transaction):
> > ------------------------------------------------------------------
> >
> > can somebody please help me with the type of 'data' in this call
> > in other words - what to do with 'data' that i get a valid python structure
>
> The storage abstraction stipulates that is is an opaque sequence
> of bytes.
>
> ConflictResolution breaks the abstraction and reveals that it
> is composed of two pickled objects.
> The first object describes the object's class the second one
> its state.
>
> The class is usually coded as a tuple: module name, class name
> but can also take another format.
>
> Look at the ConflictResolution code to learn more.
after long reading the short code of ConflictResolution -
it works (at least the first step) - reading the 'data' parameter
many thx to Dieter
fritz
(-:fs)