Two styles of acquisition are supported: explicit and implicit acquisition.
Implicit acquisition is so named because it searches for attributes from the environment automatically whenever an attribute cannot be obtained directly from an object or through inheritance.
An attribute can be implicitly acquired if its name does not begin with an underscore.
To support implicit acquisition, your class should inherit from the mix-in class Acquisition.Implicit.
When explicit acquisition is used, attributes are not automatically obtained from the environment. Instead, the method aq_acquire must be used.
Acquisition is written in Python.
Acquisition provides a powerful way to dynamically share information between objects. Zope 2 uses acquisition for a number of its key features including security, object publishing, and DTML variable lookup.
Acquisition also provides an elegant solution to the problem of circular references for many classes of problems. While acquisition is powerful, you should take care when using acquisition in your applications.
The details can get complex, especially with the differences between acquiring from context and acquiring from containment.
What's New in This Release: [ read full changelog ]
· Raise RuntimeError: Recursion detected in acquisition wrapper if an object with a __parent__ pointer points to a wrapper that in turn points to the original object.
· Prevent wrappers to be created while accessing __parent__ on types derived from Explicit or Implicit base classes.