Re: [Zope-dev] deepcopy of file object
25 Apr
2001
25 Apr
'01
5:19 p.m.
Chris Withers writes:
... copying ZODB objects ... I use the following function:
def _clone(o): """clone an object. Currently, a deep copy is used; maybe we should use a shallow copy instead.""" c= cPickle.loads(cPickle.dumps(o.aq_base,1)) c._p_oid= None return c Dieter
26 Apr
26 Apr
10:23 a.m.
New subject: [Zope-dev] deepcopy of file object
Dieter Maurer wrote:
Chris Withers writes:
... copying ZODB objects ... I use the following function:
def _clone(o): """clone an object.
Currently, a deep copy is used; maybe we should use a shallow copy instead.""" c= cPickle.loads(cPickle.dumps(o.aq_base,1)) c._p_oid= None return c
Thanks, that looks like what I'm after... Where did you find it? cheers, Chris
9134
Age (days ago)
9135
Last active (days ago)
1 comments
2 participants
participants (2)
-
Chris Withers -
Dieter Maurer