Prev | Next |
Recording Scripts
The beauty of recording is not really that we always get to see the bigger picture, but a chance to see a smaller picture that has some truth to tell. We have all seen Sequence diagrams that are less than helpful. (The same message appearing 100 times in succession on a diagram does tell us something, but not much.) Fortunately Enterprise Architect takes care of this first point through the use of fragments. Repeating behaviors are identified as Patterns and represented once as a fragment on the Sequence diagram. The fragment is labeled according to the number of iterations. The recording history, of course, always shows the entire history. We also need tools to help us focus the recording on particular areas of interest and reduce the noise from others. We can use filters to do this. With filters, you can exclude any Classes, functions, or even modules from any recording. You can create multiple sets of filters and use them with marker sets to target different Use Cases.
Access
On the Execution Analyzer window, either:
- Locate and double-click on the required script and select the 'Recording' page or
- Click on in the window Toolbar, select the Package in which to create a new script, and select the 'Recording' page
Ribbon |
Code > Configure > Analyzer > Edit Analyzer Scripts Execute > Run > Analyzer |
Keyboard Shortcuts |
|
Filter Strings
Element |
Discussion |
See also |
---|---|---|
Filtering |
If the 'Enable ' checkbox is selected on the 'Recording' page of the Execution Analyzer Script Editor, the debugger excludes calls to matching methods from the recording. The comparison is case-sensitive. To add a value, click on the 'New' ('Insert') icon in the right corner of the 'Exclusion Filters' box, and type in the comparison string; each filter string takes the form: class_name_token::method_name_token The class_name_token excludes calls to all methods of a Class or Classes that have a name matching the token; the string can contain the wildcard character * (asterisk). The method_name_token excludes calls to methods having a name that matches the token; again, the string can contain the wildcard character *. Both tokens are optional; if no Class token is present, the filter is applied only to global or public functions (that is, methods not belonging to any Class). |
Managing Analyzer Scripts Analyzer Script Editor |
Example |
In this Java example, the debugger would exclude:
In this Native Code example, the debugger would exclude:
|
Filters
Use Filter Entry |
To Filter |
---|---|
::Get* |
All public functions having a name beginning with 'Get' from the recording session (for example, GetClientRect in Windows API). |
*::Get* |
All methods beginning with 'Get' in any Class. |
CClass::Get* |
All methods beginning with Get for the CClass Class. |
CClass::* |
All methods for CClass Class. |
ATL*
|
All methods for Classes belonging to Standard Template and Active Template Libraries. |
CClass::GetName |
The specific method(s) GetName for the CClass Class. |
Learn more