Hi,

in my AixtraTable product the newItem method is defined like this:

    def newItem(self,key): #{{{
        "returns item"
        data = self._items
        if data.has_key(key):
            return None
        else:
            item = makeItem(key,self.FieldList)
            data[key] = item
            self.catalog_object(item)
            return data[key]
    #}}}

where self._items is:

        self._items = OOBTree()


and the makeItem-Class is:

class makeItem(Item): #{{{
    """
    AixtraTable Item class

    """
    def __init__(self, key, fieldlist):
        self.id = key
        for f in fieldlist:
            setattr(self,f,"")

#}}}

it only worked, when I inherited from Item, otherwise I could not access 
the items from the web, my guess is, cause they had no acquisition 
wrappers. Can I achieve the same with the __of__ magic and how ?

you can download the product from 
http://www.zope.org/Members/perry/AixtraTable




Mit freundlichen Grüßen                              Joachim Schmitz
--------------------------------------------------------------------
AixtraWare Ingenieurbüro für Internetanwendungen
Hüsgenstr. 33a, D-52457 Aldenhoven
Telefon: +49-2464-8851, FAX: +49-2464-905163
--------------------------------------------------------------------
Key fingerprint = DA10 CC82 62F8 1DBB 39A1  1EDC 725B 3317 A8D7 C3A6
Keyserver: http://www.keyserver.net/en/

_______________________________________________
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to