Overriding the Members of an Inherited Class

Note: The following applies to .NET managed code only.

When you implement a non-abstract class that inherits another class, you must override the abstract methods of the base class. Abstract methods do not contain any implementation and require that you provide an override method in the implementation of the inherited class.

Optionally, you may also override any of the virtual methods or properties of the base class. Virtual methods do contain an implementation, but the creator of the base class recognizes that it is an implementation that a derived class might need to override.

Your COBOL development system provides an easy way to override members. The Override COBOL Members dialog available in the editor:

Override the members of an inherited class using the dialog as follows:

  1. In the editor, right-click inside the class-id whose members you want to override.
  2. Choose Override Class Members.
  3. In the dialog, select the members to override.
  4. Click OK.

    This adds the construct of the override methods at the end of the derived class.

Restriction:
  • The dialog supports .NET managed code only.
  • The dialog does not support event members and members from generic classes and these are not displayed in the hierarchy tree. Generic base classes appear in the dialog as empty.