Show the other guides in this set
Table of Contents Previous section Next section

Using the Class Browser

Introduction

The Class Browser allows you to examine the classes in the current phase or package, and their associations, attributes, and operations.

Note: Only classes that appear in a CD appear in the Class Browser. If a class is defined by a CDM but does not appear in a CD, it does not appear in the Class Browser.

How to start the Class Browser

ÿ To start the Class Browser in the Browser, or in any Diagram Editor, select Utilities | Class Browser.

The Class Browser window appears. If you started the Class Browser on Phase level, all classes in that phase appear in the Classes list. If you started the Class Browser on Package level or from a diagram editor, only the classes in that package appear in the Classes list.

Layout of the Class Browser window

The Class Browser presents class information in five list boxes.

List box Information Format
Superclasses class_name
Classes class_name
Subclasses class_name
Features (Attributes) attribute_name: attribute_type The following implicit properties are displayed:
  • class attributes ($)
  • derived attributes (/)
  • keys (*)
  • initial values (= value)
  • Features (Operations) operation_name(parameter_list): operation_type where parameter_list is a sequence of (comma-separated) parameters, each having the format parameter_name: parameter_type. The following implicit properties are displayed:
  • class operations ($)
  • abstract operations ({abstract})
  • Associations Binary and n-ary associations are formatted as follows:
  • Binary: [qualifier]---association_name---role---class_name
  • N-ary: ---association_name---role---class_name,
    ---role---class_name
    , etc. The following implicit properties are displayed:
  • many (represented by an asterisk)
  • optional (represented by an O)
  • mandatory (no symbol)
  • derived associations (/)
  • How to open a class

    When you start the Class Browser or after you reload classes, only the Classes list contains data. To populate the other list boxes, you open one of the listed classes.

    ÿ To open a class, double-click a class name in the Classes list. Alternatively, select a class name in the Classes list and select File | Open.

    The other list boxes are filled with information related to the opened class.

    How to display inherited information

    By default, the Class Browser displays only the attributes and operations of the selected class, and the Associations list displays only the class at the other end of the association. Sometimes, it is useful to see the information classes inherit from their parent classes.

    ÿ To view inherited information, select View | Flat.

    All features and association entries are prefixed with the class name they belong to. The Associations list displays the classes at both ends of associations.

    ÿ To return to the default view, select View | Flat again.

    How to sort entries

    Entries in the display area are sorted alphabetically, but are not case sensitive.

    ÿ To make the sorting case sensitive, select Options | Sort Case Sensitive.

    For details on saving option settings to your user environment file, see Browser Settings in The UML Suite Project Management Guide.

    How to open a CD

    If you want to edit the diagram in which a class appears, you can open the CD directly from the Class Browser.

    ÿ To open a CD, select Utilities | Edit Class Diagram.

    The UML suite opens the CD editor and displays the CD in which the selected class appear.

    Note: If the selected class appears in more than one diagram, the UML suite prompts you to select the CD you want to edit.

    How to reload classes

    You can leave the Class Browser open while you work in a Diagram Editor or in the Browser. If you add, delete, or modify classes, you can update the Class Browser by selecting File | Reload Classes.

    Using Filters

    Introduction

    You can use filters to restrict the information displayed in the Features list. Filters are helpful when you have many attributes or operations. You set filters using the Filter Features dialog box.

    How filters work

    The Filter Features dialog box lets you set filter elements that specify which attributes and operations to display in the Features list. You can filter attributes or operations by name, data type, or by the value of any of their item properties.

    When you assign a value to a filter element, only attributes or operations matching the specified value are displayed in the Class Browser.

    For example, if you set the value of the attribute filter element Type to int, only attributes of type integer are displayed in the Class Browser.

    The Filter Features dialog box displays this information for each filter element:

    How to set a filter

    ÿ To set a filter:

    1. Select View | Filter Features.
    2. Fill out the appropriate boxes in the Filter Features dialog box. Then click OK to apply the new settings to the Class Browser.

    Navigating Between Classes

    Introduction

    You can navigate your class hierarchy in the Class Browser by opening classes in the Subclasses, Superclasses, Features and Associations lists.

    What you can open

    When you double-click an entry in the Features or Associations lists, the Class Browser looks for a class name in the entry. For example, classes sometimes appear in attribute entries as attribute data types or in operation entries as parameter data types. If the Class Browser cannot find a class name, it displays a message. The class at the other end of an association is always displayed for associations.

    In Flat view, class names prefix all entries so you can open any entry.

    How to navigate between classes

    ÿ To open a class in the Superclasses, Classes, or Subclasses lists, open a class name.

    The other list boxes display information for that class.

    ÿ To open a class in the Features list, double-click an attribute or operation entry.

    If a class name appears in the entry, it is selected and opened.

    ÿ To open a class at the other end of an association, double-click an association entry.

    Note: If you are in Flat view, a list displays with a list of class names at each end of the selected association. Click a class name and click OK.

    The class at the other end of the association is opened.

    Finding and Examining Items

    Introduction

    You can use the Class Browser to find items and to display detailed information about the items.

    How to search for a class

    ÿ To search for a class:

    1. Select File | Find Class.
    2. In the Find Class dialog box, specify a search string and click OK.

    How to search for an attribute or operation

    ÿ To search for a class attribute or operation, select File | Find Feature.

    How to examine the properties of a selected item

    ÿ To examine the properties of a particular item:

    1. Select an entry in one of the list boxes.
    2. Select Item | Show Properties.

      The Show Properties dialog box appears. This is the same dialog box that appears when you select Item | Show Properties in the Diagram Editors.

    For more information

    See Chapter 5, Properties and Stereotypes.

    How to examine the scope of a selected item

    ÿ To examine the scope of a particular item:

    1. Select an entry in one of the list boxes.
    2. Select Item | Show Scope.
    3. In the Show Scope dialog box, click OK.

    Printing from the Class Browser

    Introduction

    You can print the data of the currently opened class to the default printer. You can change the default printer option settings.

    For details on saving option settings to your user environment file, see Browser Settings in The UML Suite Project Management Guide.

    How to print class data

    ÿ To print class data, select File | Print View.

    The class data is printed on the default printer.

    How to set the default printer

    ÿ To set the default printer:

    1. Select File | Printer Setup.
    2. In the Printer Setup dialog box, specify the print command in the Printer Command box and click OK.

      The next time you print, this print command is used.

    Alternative

    You can also set the default printer from the Browser using File | Printer Setup | Text, as described in Printing.

    Changing the Class Browser Font

    Introduction

    You can specify the fonts used in the Class Browser lists by changing your font option settings.

    To save option settings to your user environment file, see Browser Settings in The UML Suite Project Management Guide.

    How to change the Class Browser font

    ÿ To change the Class Browser font:

    1. Select Options | Font.
    2. In the Class Browser Font dialog box, select a font family, style, and size. Then click OK.

      The UML suite applies the font specified.



    Table of Contents Previous section Next section


    Copyright © 2000, Telelogic AB. All rights reserved.