PowerAda The Class Browser
The Class Browser allows you to investigate the type class hierarchy of a program. The type class derivation lineage is displayed graphically, and any subclasses of a chosen type can be found on a global basis, to incrementally construct a fully type class tree. At each level in the type class hierarchy, the visible components of the type can be displayed as well as the visible primitive operations of the type class. The source declaration of the type, its attributes, and its primitive operations can be viewed by double-clicking on the type class icon, or on one of the list entries.
Contents of the Class Browser
A class browser consists of three areas:
- the type hierarchy area, which displays type hierarchy;
- the components list, which displays the visible components of the selected type in the class; and
- the primitive operations list, which displays the visible primitive operations of the selected type in the class.
Type Hierarchy Area
The type hierarchy area displays the type derivation tree with parent types towards the top and child types towards the bottom. Each icon represents a type declaration (either the root type or a derivation). Double-clicking on a type icon will activate a source browser to examine the type declaration. The child types (derivatives) of one or more types can be found by selecting the type icons and selecting Add Children from the Actions menu. This will perform a global search of all the dependent units, which may take some time.
The components area lists all the components (record components, if any) of the selected type icon. Inherited components are displayed in a regular font and new components are displayed in a bold font. Double-clicking on a component list entry will activate a source browser to examine the component declaration.
The primitive operations area lists all the primitive operations (user-defined subprograms, if any) of the selected type icon. Inherited operations are displayed in a regular font and new or overridden operations are displayed in a bold font. Double-clicking on a primitive operation list entry will activate a source browser to examine the subprogram declaration.
The working dialog is presented while the child type search is in progress. To interrupt the search, click the Interrupt button. This will cancel the search operation, retaining the current results.