8.5 Referencing an Object

Table of Contents Previous Next


8 Object Types and Objects : 8.5 Referencing an Object

object.attribute
object is the identifier assigned to the object variable. attribute is the identifier of an object type attribute.
If attribute, itself, is of an object type, then the reference must take the form:
object.attribute.attribute_inner
attribute_inner is an identifier belonging to the object type to which attribute references in its definition of object.
object.prog_name
object is the identifier assigned to the object variable. prog_name is the identifier of the procedure or function.
object_type.prog_name
object_type is the identifier assigned to the object type. prog_name is the identifier of the procedure or function.
The following anonymous block creates an instance of dept_obj_typ and calls the member procedure display_dept:
The static function defined in dept_obj_typ can be called directly by qualifying it by the object type name as follows:

8 Object Types and Objects : 8.5 Referencing an Object

Table of Contents Previous Next