Instance Environment

From STX Wiki
< Programmer Guide‎ | General Descriptions
Revision as of 15:15, 14 December 2017 by Jw (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Instance variables are preceded by the ampersand character &.

No special variables are defined for the instance environment.

You can retrieve the value of an instance variable using the syntax:

instance[!variable,varname]

For example:

$#obj[!variable,xmin]

Will return the value of the &xmin variable in the $#obj instance.

A programmer should take care about variables used in base classes and about the fact that instance variables can also be accessed and changed from outside the class/instance e.g. by using instancename.variablename in a READ command or an assignment statement.

Navigation menu

Personal tools