JavaScript Editor JavaScript Editor     JavaScript Debugger

Previous Section Next Section

Main Page

Inheritance Modifiers

By default, all classes can serve as base classes in Visual Basic .NET. However, you can use two class-level modifiers, called inheritance modifiers, to modify that behavior:

  • NotInheritable— Prevents a class being used as a base class.

  • MustInherit— Indicates that the class is intended for use as a base class only.

Note that objects of MustInherit classes cannot be created directly; they can be created only as base class instances of a derived class.

We'll see both of these modifiers in this chapter.

Previous Section Next Section

JavaScript Editor Free JavaScript Editor     JavaScript Editor