CALL METHOD - dynamic_meth
| class=>(meth_name) ...
These names are used to specify methods dynamically.
class_name expect character-like fields, which must contain the name of a method or a class in uppercase when the statement is executed. For
absolute type name can also be specified.
... (meth_name) ...
This variant is only possible for methods of the same class. It has the same effect as
me->(meth_name) (see alternative 2).
... cref->(meth_name) ...
This form is possible for all visible methods of objects.
cref can be any
variable that points to an object that contains the method specified in
meth_name. This method is searched for first in the
static type, then in the
dynamic type of
... iref->(meth_name) ...
This form is possible for all visible interface methods of objects.
iref can be any
variable that points to an object that contains the interface method specified in
meth_name. The search for this method takes place only in the
static type of
Unlike access using class reference variables, interface reference variables can only be used to access interface components, not all components (even dynamically).
... (class_name)=>(meth_name) ...
... (class_name)=>meth ...
... class=>(meth_name) ...
These forms are possible for all visible static methods. Both the class and method can be specified
dynamically. The class
class and the method
meth can also be specified directly.
In the alternatives with a dynamic class name
(class_name), first the class
is searched for, then the method. If
class is specified statically, the search for the method is carried out in the existing class.
class_name, a class of another program is specified using an absolute type name, this program is loaded into a new additional program group or into the current program group, depending on the program type (if not already loaded). If required, the program constructor is also executed.
The external calling of local class methods is critical,
especially for executable programs, module pools, and subroutine pools, since it can usually not be determined statically which program group the framework group is assigned to.