Title: Accessing the namespace of another Product/Package ? (pb when the superclass belong to another package)


In order to have a system more modular, I have split a package (product)
into several other product.

In particular, I have a package (BaseClassesPackage) that define some kind of abstract classes,
and other (more application specific) packages (Package1, Package2), that define some class
that inherit some class defined in the BaseClassesPackage.

BaseClassesPackage  (Product)

   MyClass1 (inherits MyFolderClass)

   MyClass2 (inherits MyFolderClass)

The problem is that the namespace of BaseClassesPackage is not visible
from the packages Package1 and Package2.

Any idea to fixe this ?

More generaly, do you know about any approaches / guidelines to make an application
more modular (defined in several packages that use one another)?
Does Zope 2.2 address this issue at some point ?

I have already tried to look at the code without any success.

For instance there are somewhere a few functions that can be relevant
(open somewhat the namespace):

<dtml-with manage_addProduct([anotherPackage])>
  # namespace of the package anotherPackage is available for object creation

<dtml-with "REQUEST.resolve_url(REQUEST.script + PointerToIUD)">
  # the namespace of the package where the class of the object REQUEST.script + PointerToIUD
  # is define is available.
  <small>???? (the object does not exist)</small>

There are a few (python) function that seem to have something to do with namespace and acquisition,
but it is not very clear for me how they have to be used. (in particular from within a dtml method).
aq_acquire(), DT_Util.namespace(), ...


Thierry Nabeth
Research Fellow
INSEAD CALT (the Centre for Advanced Learning Technologies)

Reply via email to