Re: What subprogram? What parameters and keywords? [message #85678 is a reply to message #85676] |
Mon, 26 August 2013 10:55   |
Michael Galloy
Messages: 1114 Registered: April 2006
|
Senior Member |
|
|
On 8/26/13 8:14 AM, Mats Löfdahl wrote:
> Den måndagen den 26:e augusti 2013 kl. 15:46:24 UTC+2 skrev Mats
> Löfdahl:
>>
>> So did my overloading not work?
>
> This is new to me. I'm just working with a class written by someone
> else...
>
> Reading further (http://www.exelisvis.com/docs/IDL_Object.html), I
> realized I also had to add the line "INHERITS IDL_Object" to the
> class structure.
>
> Hmmm... And I don't have a "PRO myObjectClass__define", I just have
>
> struct = {red, ....., INHERITS IDL_Object} tmp = obj_new('red')
>
> in a function definition. This is in IDL 7.1.1.
Well, technically, if the "struct = { red, ... }" line is executed
before you try to create the object then you have defined your object's
variables, but I would recommend that put the variable definitions in
the appropriately named file: red__define.pro in the "red__define"
procedure. This will make sure IDL (and you) can find the definition
whenever it is needed.
Mike
--
Michael Galloy
www.michaelgalloy.com
Modern IDL: A Guide to IDL Programming (http://modernidl.idldev.com)
Research Mathematician
Tech-X Corporation
|
|
|