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

Home » Public Forums » archive » Re: Object Method validity
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Object Method validity [message #36180 is a reply to message #36177] Wed, 13 August 2003 10:00 Go to previous messageGo to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
rmmoss@cox.net (Robert Moss) writes:
> Is there a way to verify the existance of a particular object method?
> Something like
>
> valid = Method_Valid( theObject, "HopedForMethod" )
>
> I guess. I've spent a little while rtfm-ing and googling to no avail.

How about using:
pronames = [routine_info(), routine_info(/func)]
wh = where(pronames EQ strupcase(CLASSNAME+'::'+METHODNAME), ct)
if ct GT 0 then print, 'Method found!' else print, 'Method NOT found!'

This assumes the class is already compiled. Also, if you want
system-level classes, you will need to use the appropriate keywords to
ROUTINE_NAMES().

Craig


--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@cow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Embedding colour IDL syntax in Word
Next Topic: Welcome to ITOOLS....

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

Current Time: Wed Oct 08 14:10:44 PDT 2025

Total time taken to generate the page: 0.00527 seconds