comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Determine if class has method/property
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Determine if class has method/property [message #44436] Mon, 13 June 2005 14:00
Michael Wallace is currently offline  Michael Wallace
Messages: 409
Registered: December 2003
Senior Member
Is is possible to dynamically determine if a given class has a certain
method defined? Similarly, is it possible to determine if a class has a
certain property defined?

I'm attempting to be a good programmer and validate some of my input and
displaying nice error message rather than just handing it off to IDL and
letting IDL return a nice cryptic (at times) message. It turns out that
my code is filling up with a bunch of OBJ_ISA statements because I have
to check each class that could be used. While these classes all have
the same methods defined, those methods are not present in their
superclass, so I can't just do a simple check to see if a given class is
an instance of the superclass. I can't change the superclass so my
options are either to write my own specific OBJ_ISA functions that do
all the checking for me or determine if the class in question has a
certain method defined before I try to use it. I'm just wondering if
the latter is possible before I go off writing my specific versions of
OBJ_ISA.

-Mike
[Message index]
 
Read Message
Previous Topic: deallocating ptrs
Next Topic: Re: data inside a circle

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Mon Oct 27 15:42:11 PDT 2025

Total time taken to generate the page: 2.56197 seconds