I'm looking for an internal globally unique identifier for objects in my
Zope store.

I know that I can use id=object.absolute_url() to create an identifier and
then <something>.resolve_url(id) to recover the object from the identifier
-- but I have two problems with this API:

1. The URL is not really a global identifier, as resolving it seems to
depend on the <something> from which I call resolve_url().  In particular,
if the id is created when Zope is running normally (as a service), and
resolved when running Zope from the command line debugger, the resolve
fails.  This is not good.

2. The need to locate an object <something> carrying the resolve_url()
function is a problem; in particular, I would find it helpful if I could
resolve my global identifier from within a __setstate__() method (where I
have no access to local Zope variables), so I really want a genuinely global
function for resolving my id.

Any suggestions, or do I have to dig into the (disagreeable and uncommented)
bowels of Zope and write my own?

(If this is on the wrong list, please point me to the right one.  Thanks.)

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

Reply via email to