Re: [Zope] non-persistent publishable objects
----- Message from Terry Hancock <hancock@anansispaceworks.com> on Fri, 23 Jan 2004 15:54:12 -0600 -----
You will note that these object inherit from either Acquisition.Explicit or Acquisition.Implicit -- you will probably need that to make them useful. You will also need to define a security manager for the object. And don't forget to call
Globals.InitializeClass(...)
How is Globals.InitializeClass(...) different from registering a class within __init__.py? Is a publishable class not necessarily the same as a product class, then? You also used a meta_type attribute. Do you know if this is necessary? Furthermore, do you think it is possible to store local roles in my relational tables to feed Zope's security machinery? That would be too cool!
*In concept only -- they don't use Zope's "pluggable brain" facilities which are intended for through-the-web use. Personally, I can't help thinking "Peanut Butter" everytime I see it, but what the hey.
Do you know about Twisted? From their website: The components that Twisted Spread provides are as follows: * pb: pb is the Perspective Broker. It lets you talk to remote objects, implementing semantics for object copying, caching, and referencing. * jelly: serialization for Python objects * banana: low level data marshaller
nwingfield@che-llp.com wrote:
How is Globals.InitializeClass(...) different from registering a class within __init__.py?
registering a class makes it available to add through ZMI, etc, probably not important if it's not persistent. initializing it "turns on" any security declarations you have made about that class in the code, which you probably DO want to do.
You also used a meta_type attribute. Do you know if this is necessary?
Probably not, unless the class is persistent.
Furthermore, do you think it is possible to store local roles in my relational tables to feed Zope's security machinery? That would be too cool!
Have a look at LDAPUserFolder, particularly the satellite roles thing, you may be able to do something similar... FWIW, I'd like to add that ability to SimpleUserFolder at some point :-) cheers, Chris
participants (2)
-
Chris Withers -
nwingfield@che-llp.com