On Monday 08 August 2005 12:43, Adam Groszer wrote:
> class IItem(interface):
>     unit = Object(
>         title=u"Unit",
>         description=u"Unit",
>         required = False,
>         schema=IUnit)
>
> class IUnit(interface):
>     item = Object(
>         title=u"Item",
>         description=u"Item",
>         required = False,
>         schema=IItem)
>
> but obviously that does not work, I cannot define one before the
> other.

In IItem specify "Interface" as the schema. After you defined IUnit you can do 
something like:

IItem.getDescriptionFor('unit').schema = IUnit

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to