Search conditions

When you search UML models, you can customize the search by specifying search conditions. You can choose conditions to make your search either more specific or more general. Specific searches typically return fewer results than general searches.

Note: A word means the characters are separated by a space, tab, newline, or return, or the following symbols:

! : ; { } ( ) , . ? ' " \

The following table contains the search conditions that you can specify in the Find and Replace windows. Several of the search conditions are only available when you click the Advanced button.

Search Conditions Description Example
Match whole word

You can use the Match whole word only check box to search for occurrences that are whole words and not part of a larger word.

If you select the this check box and search for "Package1", the search can find "Package1(a)" or Package1[a] but it cannot find "Package1a".

Match case

You can use the Match case check box to indicate that the search is case sensitive, meaning that the search looks only for text with the same capitalization as the text that you specify in the Find what field.

If you select this check box and search for "Rational", the search finds only the word "Rational". If you clear this check box, the search looks for any text that matches the text specified in the Find what field, regardless of its capitalization.

For example, if you clear this check box and search for "Rational", the search finds both "rational" and "Rational".

Do not search on diagrams

You can use the Do not search on diagrams check box to limit the search to model elements in the model.

If a model contains a class model element that is represented by a class diagram element in a diagram, the search finds only the class model element. If you clear this check box, the search also looks for diagram elements and relationships in diagrams.

Advanced > Fields

In the Find and Replace windows, the Fields list opens after you click the Advanced button. You can use the list to specify whether you want to search model element names, the model element documentation, or both.

If you select the Documentation check box, the search ignores any instances of the text that you are searching for in the model element name; the search only looks through model element documentation.

Advanced > Types

In the Find and Replace windows, the Types list opens after you click the Advanced button. You can use the list to select the types of model elements to include in the search. An icon and name represent each type of model element and relationship. If you select a check box, the search includes that type of model element or relationship.

If you select the Class check box, the search finds classes with the text that you specify in the Find what field. If you clear the check box, the search filters out that type of model element or relationship. For example, if you clear the Class check box, the search does not find any classes, even if a class name contains the text specified in the Find what field.

Advanced > Additional OCL Filter

You can use the Additional OCL Filter field, which opens after you click the Advanced button, to enter an Object Constraint Language (OCL) expression to use as a filter based on existing results.

If you enter an OCL expression, you can use the filter to search through existing find and replace results.

Related tasks
Searching models
Finding text in models
Replacing text in models

Terms of use | Feedback
(C) Copyright IBM Corporation 2004, 2005. All Rights Reserved.