How to check if an object is Folderish ?
Hi, All's in the title ! is there something like "ob.isFolderish()" that ignores acquisition ? Thanks in advance --Gilles
cant you use obj.aq_explicit.isFolderish() ?? Robert ----- Original Message ----- From: "Gilles Lenfant" <gilles@pilotsystems.net> To: <zope@zope.org> Sent: Thursday, February 06, 2003 9:18 PM Subject: [Zope] How to check if an object is Folderish ?
Hi,
All's in the title ! is there something like "ob.isFolderish()" that ignores acquisition ?
Thanks in advance
--Gilles
_______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
ObjectManagers define 'isAnObjectManager=1'. You could do something like: from Acquisition import aq_base def is_folderish(object): return getattr(aq_base(object), 'isAnObjectManager', 0) HTH, Stefan --On Donnerstag, 06. Februar 2003 21:18 +0100 Gilles Lenfant <gilles@pilotsystems.net> wrote:
Hi,
All's in the title ! is there something like "ob.isFolderish()" that ignores acquisition ?
Thanks in advance
--Gilles
-- Those who write software only for pay should go hurt some other field. /Erik Naggum/
participants (3)
-
Gilles Lenfant -
Robert Rottermann -
Stefan H. Holek