[Zope] Is this it? THANK YOU!

Andrew Kenneth Milton akm@theinternet.com.au
Mon, 1 Oct 2001 22:46:43 +1000


+-------[ tom smith ]----------------------
| Andrew,
| 
| > Yes there is... 
| > 
| > self = context.this()
| 
| 
| Thank you, thank you, , thank you, thank you, thank you, thank you, thank
| you, thank you, thank you, thank you, thank you, thank you, thank you, thank
| you, thank you. This will let me stop keeping all my code objects in the
| same folder, very messy!

hehe.

| 
| Do you know of any documentation about context.this() anywhere? Lord knows,
| I've looked but missed that one...

context is a MultiMapping (Zope Name), (or an object that contains some 
number of them), which is basically a stack of dictionaries containing 
your namespace. As you pass through each object between / and you more 
information is pushed on the namespace stack.

Most (Zope) objects contain a this() method that returns self, so
this() is simply your container (I'm sure it's not you, but, I might be 
mistaken here, it makes little difference), which has a full acquisition 
wrapper.

-- 
Totally Holistic Enterprises Internet|                      | Andrew Milton
The Internet (Aust) Pty Ltd          |                      |
ACN: 082 081 472 ABN: 83 082 081 472 |  M:+61 416 022 411   | Carpe Daemon
PO Box 837 Indooroopilly QLD 4068    |akm@theinternet.com.au|