[Zope-dev] Properties Introspection

Tres Seaver tseaver@palladion.com
Mon, 28 Feb 2000 18:24:22 -0600


Josh Zeidner <jmz_phylogenic@hotmail.com> asked:
> 
>   I am trying to develop a way to dynamically introspect an objects
> properties( specifically, a ZClass ).  How can I determine which sub-objects
> of a Zope object are properties?  Can I do this in DTML or do I need to use
> python?

Umm, does the 'hasProperty()' method do what you want?

  <dtml-if "hasProperty( 'Foo' )">
    <p>My Foo property is <dtml-var Foo>.</p>
  </dtml-if>

-- 
=========================================================
Tres Seaver         tseaver@palladion.com    713-523-6582
Palladion Software  http://www.palladion.com