[Zope-dev] Aquisition.Acquired

Chris Withers chrisw@nipltd.com
Wed, 10 Jan 2001 18:11:02 +0000


Shane Hathaway wrote:
> 
> There's a (much) simpler way:
> 
> class MyClass(Acquisition.Explicit):
>     your_attribute = Acquisition.Acquired
> 
>     # index_html isn't
>     index_html = None
> 
> "Acquired" is a special object that the acquisition module looks for.

Just noticed you can do this also:

class MyClass: # note lack of base class ;-)
     your_attribute = Acquisition.Acquired
 
...got the idea from Traversable.py

Now if I could just figure out how to make non-SimpleItem classes aware
of security (see my other recent post :-S)

cheers,

Chris