Re: [Zope-dev] Typo in Version.py

2000-10-18 Thread Jeffrey P Shell

On 10/18/2000 9:04 AM, "Greg Ward" [EMAIL PROTECTED] wrote:

 Now if only I could figure out why Zope is trying to raise that
 exception on me... (I'm not deleting a version, I'm just renaming
 something within a version!)
 
   Greg

Because Rename deletes.  The basic sequence of a renameObject command is (in
short):

In short, it:
1.Gets the object off of the objectmanager using the old id.
2.Deletes it from the objectmanager (doesn't delete the object
  itself!).
3.Changes the id of the object.
4.Adds it back to the objectmanager with the new id.

The detailed version is:
1.Check ID (is the new id invalid or already used?), raise
  Invalid ID if so.
2.Get the object using _getOb
3.Check if object supports copying\moving using cb_isMoveable,
  raise CopyError
4.Use _verifyObjectPaste (Does some verification to make sure the
  user.
5.Try to notify recipient of the copy (in this case "self" - the
  ObjectManager or other CopySupport-subclassed class instance),
  if that fails, raise a Rename Error.
6.Delete the object off of the object manager (self._delObject)
7.If possible, get the aq_base of the object, then set the objects
  id to the new id.
8.Set the modified object on the ObjectManager, leaving the ownership
  info unchanged.  (self._setObject).


Jeffrey P Shell, [EMAIL PROTECTED]
http://www.digicool.com/ | http://www.zope.org



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] Typo in Version.py

2000-10-18 Thread Jeffrey P Shell

On 10/18/2000 9:27 AM, "Jeffrey P Shell" [EMAIL PROTECTED] wrote:

 On 10/18/2000 9:04 AM, "Greg Ward" [EMAIL PROTECTED] wrote:
 
 Now if only I could figure out why Zope is trying to raise that
 exception on me... (I'm not deleting a version, I'm just renaming
 something within a version!)
 
   Greg
 
 Because Rename deletes.  The basic sequence of a renameObject command is (in
 short):

Actually, I'm not sure what you're asking here: are you renaming the Version
object itself?  Or renaming something else while inside the version?

Jeffrey P Shell, [EMAIL PROTECTED]
http://www.digicool.com/ | http://www.zope.org



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )