On this page

MagicDraw utilizes a Find operation that allows you to automatically search for model elements, represent relations between these elements, or gather their derived property values each time you update your model. The Find operation is customizable, so you can change the default values of all the properties for the selected operation at any any time. The Find operation can be accessed and used:

  • In a Relation Map to represent relations between elements.
  • In a Dependency Matrix to associate elements in rows and columns of a matrix.
  • From the Specification window of a Smart Package to query a model and gather specific elements.
  • From the Specification window of the selected element to calculate/gather the values of derived properties.
  • In a Generic Table to calculate/gather the values of derived properties.
  • From the Specification window of an opaque behavior to specify the body of a StructuredExpression.
     

Tip

If you would like to simply find the desired model element, and don't need to automatically query your model every time you update it, use the Find dialog instead.

To use a Find operation, you need to specify it as criteria. The next section describes how to complete this task.

Specifying a Find operation as criteria

Specifying a Find operation as criteria allows you to automatically query your model in order to find and render specific model elements, relations between these elements, or gather their derived properties depending on where the operation is used (as mentioned above).


To specify a Find operation as criteria


  1. Open the dialog for specifying criteria.
  2. Select Find on the left side of the open dialog.
  3. Change the Operation Name, if needed.

  4. Select the Style to represent the specified Find criteria. Note that the style selection is available only in the Relation Criteria and Dependency Criteria dialogs.

  5. Specify the Find operation properties, and click OK.
     

Useful information

Selecting the Search in all texts check box allows you to search for text in Documentation and TODO properties.

Advanced Manipulations

Specifying the Find operation properties 

To specify the Find operation properties 


  1. Open the dialog for specifying criteria.
  2. On the left side of the dialog, expand the Find operation.
  3. Select the property you want to specify, and, in the property specification panel on the right side of the dialog, specify the value of the selected property.
  4. Click OK.
    The selected Find operation is now customized to query a model according to your specified properties. You can use a specific Find operation as an argument of another operation. In other words, you can create a new Find, Filter, Implied Relation, Exclude, Script, Union or Collection operation, and use the results of a specific Find operation as its property. 

To use the expression of a Find operation as a property of another operation

To use the expression of a Find operation as a property of another operation


  1. Open the dialog for specifying criteria.
  2. Select Find on the left side of the dialog.
  3. In the criteria specification panel on the right side of the dialog, click the Use as button, and select the desired command that corresponds to the operation you want to create as shown below. A new operation is created.

  4. Specify other parameters of the created operation, and click OK.
    You now have a new operation that has been created with the selected Find operation as one of its properties.