Rosert Toolset Guide PDF
Rosert Toolset Guide PDF
Toolset Guide
RATIONAL ROSE® REALTIME
VERSION: 2003.06.00
WINDOWS/UNIX
[email protected]
http://www.rational.com
Legal Notices
©1993-2003, Rational Software Corporation. All rights reserved.
This manual (the "Work") is protected under the copyright laws of the United States
and/or other jurisdictions, as well as various international treaties. Any reproduction
or distribution of the Work is expressly prohibited without the prior written consent
of Rational Software Corporation.
Portions covered by U.S. Patent Nos. 5,193,180 and 5,335,344 and 5,535,329 and
5,574,898 and 5,649,200 and 5,675,802 and 5,754,760 and 5,835,701 and 6,049,666 and
6,126,329 and 6,167,534 and 6,206,584. Additional U.S. Patents and International
Patents pending.
U.S. GOVERNMENT RIGHTS. All Rational software products provided to the U.S.
Government are provided and licensed as commercial software, subject to the
applicable license agreement. All such products provided to the U.S. Government
pursuant to solicitations issued prior to December 1, 1995 are provided with
“Restricted Rights” as provided for in FAR, 48 CFR 52.227-14 (JUNE 1987) or DFARS,
48 CFR 252.227-7013 (OCT 1988), as applicable.
WARRANTY DISCLAIMER. This document and its associated software may be used
as stated in the underlying license agreement. Except as explicitly stated otherwise in
such license agreement, and except to the extent prohibited or limited by law from
jurisdiction to jurisdiction, Rational Software Corporation expressly disclaims all
other warranties, express or implied, with respect to the media and software product
and its documentation, including without limitation, the warranties of
merchantability, non-infringement, title or fitness for a particular purpose or arising
from a course of dealing, usage or trade practice, and any warranty against
interference with Licensee’s quiet enjoyment of the product.
Microsoft, the Microsoft logo, Active Accessibility, Active Client, Active Desktop,
Active Directory, ActiveMovie, Active Platform, ActiveStore, ActiveSync, ActiveX,
Ask Maxwell, Authenticode, AutoSum, BackOffice, the BackOffice logo, bCentral,
BizTalk, Bookshelf, ClearType, CodeView, DataTips, Developer Studio, Direct3D,
DirectAnimation, DirectDraw, DirectInput, DirectX, DirectXJ, DoubleSpace,
DriveSpace, FrontPage, Funstone, Genuine Microsoft Products logo, IntelliEye, the
IntelliEye logo, IntelliMirror, IntelliSense, J/Direct, JScript, LineShare, Liquid Motion,
Mapbase, MapManager, MapPoint, MapVision, Microsoft Agent logo, the Microsoft
eMbedded Visual Tools logo, the Microsoft Internet Explorer logo, the Microsoft
Office Compatible logo, Microsoft Press, the Microsoft Press logo, Microsoft
QuickBasic, MS-DOS, MSDN, NetMeeting, NetShow, the Office logo, Outlook,
PhotoDraw, PivotChart, PivotTable, PowerPoint, QuickAssembler, QuickShelf,
RelayOne, Rushmore, SharePoint, SourceSafe, TipWizard, V-Chat, VideoFlash, Visual
Basic, the Visual Basic logo, Visual C++, Visual C#, Visual FoxPro, Visual InterDev,
Visual J++, Visual SourceSafe, Visual Studio, the Visual Studio logo, Vizact, WebBot,
WebPIP, Win32, Win32s, Win64, Windows, the Windows CE logo, the Windows logo,
Windows NT, the Windows Start logo, and XENIX, are either trademarks or registered
trademarks of Microsoft Corporation in the United States and/or in other countries.
Sun, Sun Microsystems, the Sun Logo, Ultra, AnswerBook 2, medialib, OpenBoot,
Solaris, Java, Java 3D, ShowMe TV, SunForum, SunVTS, SunFDDI, StarOffice, and
SunPCi, among others, are trademarks or registered trademarks of Sun Microsystems,
Inc. in the U.S. and other countries.
Purify is licensed under Sun Microsystems, Inc., U.S. Patent No. 5,404,499.
Licensee shall not incorporate any GLOBEtrotter software (FLEXlm libraries and
utilities) into any product or application the primary purpose of which is software
license management.
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxvii
Audience. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxviii
Other Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxviii
Rational Rose RealTime Integrations With Other Rational Products . . . . . xxix
Contacting Rational Customer Support . . . . . . . . . . . . . . . . . . . . . . . . . . . .xxx
1 Using the Online Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Using the Online Help System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Accessing What’s This Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Accessing Extended Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Tutorials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Using the Help Viewer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Getting More Out of Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Finding a Help Topic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Creating a List of Favorite Help Topics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Maintaining a Single Favorites List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Copying a Help Topic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Printing the Current Help Topic. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Obtaining Help in a Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Finding Topics Using the Toolbar Buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Hiding or Showing the Navigation Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Using Accessibility Shortcut Keys in the Help Viewer . . . . . . . . . . . . . . . . . . . . . 6
Using the Context Menu Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
About the Search Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Searching for Help Topics . . . . . . . . . . . . . . . . . . . . . . . . . . ...... ....... .. 10
Searching for Words or Phrases. . . . . . . . . . . . . . . . . . . . . . ...... ....... .. 11
Defining Search Terms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ...... ....... .. 12
Using Nested Expressions when Searching. . . . . . . . . . . . . ...... ....... .. 12
Searching within Search Results . . . . . . . . . . . . . . . . . . . . . ...... ....... .. 14
Contents v
Changing the Help Viewer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .14
Customizing the Help Viewer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Changing Format or Styles for Accessibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Viewing Topics Grouped by Information Type. . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Changing the Font Size of a Topic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Changing Colors in the Topic Pane of the Help Viewer . . . . . . . . . . . . . . . . . . . 16
Related Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16
2 Overview of Rational Rose RealTime . . . . . . . . . . . . . . . . . . . . . . . 17
Developing Using Rational Rose RealTime . . . . . . . . . . . . . . . . . . . . . . . . . .17
Using Languages and Code Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . .18
Compiling Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Using the Services Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19
Capsules, Protocols, Ports, Capsule State and Structure Diagrams . . . . . . .19
Capsules. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Protocols. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
State Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Capsule Structure Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Executable Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Constructing Models in Rational Rose RealTime . . . . . . . . . . . . . . . . . . . . .22
Modeling Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Required Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .22
Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Development Process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25
Essential Workflows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26
3 User Interface Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
Startup Screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
Create New Model Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30
Using the Startup Frameworks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Application Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
Browsers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
Toolbar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
Diagrams. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
Toolboxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
Menu Bar. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
About Rational Rose RealTime Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
vi Contents
The Toolbar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .39
Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .43
Menu Bar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
File Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
File Menu Operations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Edit Menu . . . . . . . ...... ....... .................................. 49
Parts Menu . . . . . . ...... ....... .................................. 54
View Menu . . . . . . ...... ....... .................................. 56
Browse Menu . . . . ...... ....... .................................. 57
Select Diagram Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
Browse Menu Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Build Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Report Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Query Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Tools Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Add-Ins Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Window Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Help Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
Browsers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .78
Tabs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Model View Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Containment View Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Inheritance Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
RTS Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Navigating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Displaying the Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
Refreshing the Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
Multiple Browsers. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
Filtering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
Diagram Editors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .82
Diagram Specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Diagram Specification - Diagrams Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Adding Icons to a Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Opening Specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
Shortcut Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
Background Shortcut Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
Scroll Bars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Contents vii
Overview Navigator and Toolset Buttons, and Class, Capsule, and Protocol
Specification Context Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
Overview Navigator Button . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
Toolset Buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
Context Options for Specification Dialogs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
Context Options for Other Controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .87
Sequence Diagram Context Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Toolboxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
Specification Dialogs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .92
Spreadsheet-type Functionality for List Controls within a Specification Dialog. . . . . .93
Tabs. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .95
Actions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
Attributes Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
Components Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Operations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Swimlanes Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Transitions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Unit Information Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Scratch Pad Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
Searching and Sorting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .104
Using Sort. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104
Find In Model Dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
Replace Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
Searching Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .106
4 Other Application Windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109
Description Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .109
Displaying the Description Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109
Documentation Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
Code Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
Word Wrap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
Pull-down Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111
Popup Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111
viii Contents
Adding Documentation to Model Elements . . . . . . . . . . . . . . . . . . . . . . . . .111
Adding Code to Model Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .112
Output Window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .112
Log Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
Build Log Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113
Saving Build Output to a Log File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113
Build Errors Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
Filtering Build Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
Sorting Build Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
Unknown Compiler Message Stream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
Find Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
Watch Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
Refreshing the Watch Values. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
Specification History Window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .115
Locking Specification Dialogs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
ToolTips . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
Keyboard Shortcuts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
Specification History Shortcut Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
5 Printing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
Print Specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .119
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
Properties Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120
Diagrams Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120
Specifications Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
Layout Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122
Print Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .123
Printer Area . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Paper Area. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Orientation Area. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
6 Opening and Saving Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Unique Ids . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .125
Opening Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .129
Model Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
Source Control Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130
Unit Information Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130
A Workspace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
User-specific Working Environment Settings (.rtusr, .rtto and .rtwks) . . . . . . . 132
Contents ix
Opening Models from ObjecTime Developer 5.2.1 . . . . . . . . . . . . . . . . . . .132
Limitations and Restrictions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
Opening Rational Rose Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .134
Limitations and Restrictions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
Importing Rational Rose Generated Code. . . . . . . . . . . . . . . . . . . . . . . . . .136
Limitations and Restrictions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136
7 Use Case Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137
Creating a Use Case Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .137
Using the Use Case Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .138
Usage Tips . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
Use Case Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
8 Defining Use Cases and Actors . . . . . . . . . . . . . . . . . . . . . . . . . . 141
Creating a Use Case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .141
Use Case Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142
Diagram Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .143
Creating an Actor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .143
Actor Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
9 Creating Class Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
Creating a Class Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .145
Using the Class Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
Class Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 149
Creating Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .153
Creating Association Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .154
Association Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .155
Association Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
End A and B General Tabs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
End A and B Detail Tabs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
Creating Aggregation Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .160
Creating an Association Class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .162
Aggregation Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .162
x Contents
Creating Inheritance Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .162
Creating an Inheritance Tree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
Exclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
Generalize Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
Inheritance in Rational Rose RealTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
Promoting and Demoting Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
Potential Conflicts Caused by Promote/Demote . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
Excluding Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
Reinheriting Excluded Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166
Rearranging Inheritance Hierarchies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166
Inheritance Tab in Browser. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166
Creating Dependency Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .167
Graphical Notation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Naming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Valid Applications. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Add Class Dependencies Wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Dependency Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169
Creating Reflexive Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .170
Changing the Directionality of an Association . . . . . . . . . . . . . . . . . . . . . . .170
Creating Package Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .170
Creating Realize Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .171
Naming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
Valid Applications. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
Realize Relationship Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
Inserting Dependencies, Generalizations, and Realizations on the Relations
Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .172
Inserting Dependencies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
Inserting Generalizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173
Inserting Realizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
Changing the End Class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176
Adding and Hiding Classes, and Filtering Class Relationships . . . . . . . . . .178
Using State Machine Code Generation for Classes. . . . . . . . . . . . . . . . . . .178
Configuring a Simple Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
Generating Component Libraries for Classes without RTS Dependencies . . . 180
Creating State Machine Trigger Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
Configuring the trigger Stereotype for an Operation . . . . . . . . . . . . . . . . . . . . 183
Contents xi
Generating State Machine Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
Support for Code Sync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189
Hello World Implementation and Header Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
Using Constructors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
C Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196
C++ Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197
Using Return, Break, and Continue Statements. . . . . . . . . . . . . . . . . . . . . . . . 198
Specifying History. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
No Refinement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
Overriding Virtual Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
Generation of Parameterized and Instantiated Classes. . . . . . . . . . . . . . . .200
Parameterized Classes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
Instantiated Classes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
Relationships . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
10 Creating Collaboration Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . 207
Creating Capsule Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .207
Using the Structure Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .208
UML Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .209
Structure Diagram Browser Context Menu Options . . . . . . . . . . . . . . . . . . . . . . . . . 209
Structure Diagram Toolbox. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .211
Creating a Port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .212
Creating a Non-Wired Port Using a System Protocol . . . . . . . . . . . . . . . . . . . . . . . . 213
Port Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .213
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .217
Port Role Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .218
Adding a Capsule Role . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .219
Capsule Role Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .219
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
Connecting Ports on Capsule Roles Together . . . . . . . . . . . . . . . . . . . . . . .221
Connector Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .221
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221
Creating a Collaboration Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .222
xii Contents
Using the Collaboration Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . .222
Relationship Between Collaborations and Sequences . . . . . . . . . . . . . . . . . . . . . . 223
Opening a Sequence Diagram. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
Sequence Overlays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
Code Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
Collaboration Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
Classifier Role Specification. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Association Role Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
11 Creating State Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
Creating Capsule State Machines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .229
Using the State Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .230
State Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
State Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
Entry Actions / Exit Actions Tabs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
Aggregating and Decomposing State Machines . . . . . . . . . . . . . . . . . . . . .235
Transition Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .235
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235
Triggers Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235
Actions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
Choice Point Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .237
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
Condition Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
Initial State Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .237
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238
Junction Point Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .238
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
Event Editor Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .239
EventGuard Specification Dialog Box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
Adding a State . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .242
Adding a Choice Point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .242
Contents xiii
Drawing Transitions Between States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .242
Specifying the Transition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
Drawing the Initial Transition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .245
Defining State Transition Trigger Events . . . . . . . . . . . . . . . . . . . . . . . . . . .246
State Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 246
Joining Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .247
Creating Nested States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .248
Positioning from a Superclass for Transitions . . . . . . . . . . . . . . . . . . . . . . .248
State Diagram - Showing Triggers and Code for Transitions . . . . . . . . . . . .250
Identifying Self Transitions on the Transitions Tab in the State Specification
Dialog Box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .254
Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255
12 Creating Activity Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257
Modeling Using Activity Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .258
Activity Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 258
Creating an Activity Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .260
Activity Diagram Specification Dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .261
Activity Diagram Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . 262
StateMachine Specification for State/Activity . . . . . . . . . . . . . . . . . . . . . . . .262
StateMachine Specification for State/Activity - General Tab. . . . . . . . . . . . . . . 262
StateMachine Specification for State/Activity - Files Tab . . . . . . . . . . . . . . . . . 263
Activity Diagram Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .263
Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .264
Activity History . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
Specifying Actions for Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
Nested Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 265
Manipulating Nested Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .265
Creating Nested Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 265
Activity Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .266
Activity Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266
Activity Specification Dialog - Actions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
Activity Specification Dialog - Transitions Tab. . . . . . . . . . . . . . . . . . . . . . . . . . 268
Activity Specification Dialog - Swimlanes Tab . . . . . . . . . . . . . . . . . . . . . . . . . 268
Activity Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
xiv Contents
Actions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .269
Action Specification Dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .270
Action Specification Dialog - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
Action Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
Decisions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .271
Decision Specification Dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .272
Decision Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . 272
Decision Specification Dialog - Transitions Tab . . . . . . . . . . . . . . . . . . . . . . . . 273
Decision Specification Dialog - Swimlanes Tab . . . . . . . . . . . . . . . . . . . . . . . . 273
Decision Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
End State . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .274
Start State . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .274
States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .275
Specifying Actions for States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
Nested States. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
Manipulating Nested States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
Creating Nested States . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
State History . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
State Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .277
State Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
State Specification Dialog - Actions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
State Specification Dialog - Transitions Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
State Specification Dialog - Swimlanes Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
State Specification Dialog - Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280
Trigger Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .280
Trigger Specification Dialog - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280
Trigger Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
Synchronizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .281
Synchronization Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .282
Synchronization Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . 282
Synchronization Specification Dialog - Transitions Tab . . . . . . . . . . . . . . . . . . 283
Synchronization Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . 283
Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .283
Contents xv
Transition Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .284
Transition Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . 284
Transition Specification Dialog - Detail Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
Transition Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
Swimlanes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .286
Creating Swimlanes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
Deleting a Swimlane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
Moving a Swimlane. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
Displaying Multiple Views of a Swimlane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
Changing the Assignment of Responsibility of a Swimlane . . . . . . . . . . . . . . . 289
Swimlane Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .289
Swimlane Specification Dialog - General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . 289
Swimlane Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
Objects and Object Flows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .290
Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
Object State . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
Object Flow. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
Object Flows and Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
Modeling Object State changes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
Creating an Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
Creating an Object Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
Adding the Object, Object Flow, and Lock Selection Tools to the Toolsbar . . . 293
Object Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .294
Object Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
Object Specification Dialog - Incoming Object Flows Tab . . . . . . . . . . . . . . . . 296
Object Specification Dialog - Outgoing Object Flows Tab . . . . . . . . . . . . . . . . 296
Object Specification Dialog - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296
Object Flow Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .296
Object Flow Specification Dialog - General Tab . . . . . . . . . . . . . . . . . . . . . . . . 297
Object Flow Specification Dialog - Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . 297
Cutting Objects on Activity Diagrams. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .298
Copying Objects on Activity Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . .298
Pasting Objects on Activity Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . .298
xvi Contents
13 Creating Sequence Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
Creating a Sequence Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .299
Creating a New Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
From the Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
From the Structure Diagram Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
From the Collaboration or Structure Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
Editing a Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
Adding Instances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301
Defining Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 302
Specifying Message Details. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 302
Cloning a Sequence Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .302
Using Copy and Paste within Sequence Diagrams . . . . . . . . . . . . . . . . . . .302
Interaction Instances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303
Messages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303
Standard Diagram Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305
Known Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305
Using the Sequence Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .305
Opening Collaboration Diagrams. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306
Reorienting Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306
Moving Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307
Sequence Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .307
Interaction Instance Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 310
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 310
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311
Interaction Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311
Local Action Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
Local State Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313
Message Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313
Port Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314
Send Message Specification - Adding Ports to Capsule Classes . . . . . . . .315
Sequence Validation Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .318
Contents xvii
Focus of Control. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .319
Coloring a Focus of Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320
Navigating Sequence Diagrams. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .321
Saving Sequence Diagrams as Controlled Units . . . . . . . . . . . . . . . . . . . . .324
Uncontrolling Sequence Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326
Importing and Exporting Sequence Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326
RRTEI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326
Control Interaction Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326
ControlInteractions_CheckOut.ebs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .327
ControlInteractions_AddSequenceDiagrams.ebs . . . . . . . . . . . . . . . . . . . . . . . . . . .327
ControlInteractions_CheckIn.ebs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328
Running Scripts to Make Sequence Diagrams Controllable . . . . . . . . . . . . . . . 328
14 Defining Capsules and Classes . . . . . . . . . . . . . . . . . . . . . . . . . . 333
Creating a Class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .333
Creating New Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .334
Creating New Operations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .334
Class Specification. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .335
Class Specification Content . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335
Class Specification - General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336
Class Specification - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
Class Specification - Operations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339
Class Specification - Attributes Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
Class Specification - Nested Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
Class Specification - Components Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
Class Specification - Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
Class Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 345
Class Specification - Diagrams Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 345
Attribute Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .345
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 347
Operation Specification Dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .347
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
Validation Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 350
Semantics Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352
xviii Contents
Parameter Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .352
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 353
Creating a Capsule Class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .353
Capsule Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .354
State Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
Structure Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
Undocking the Capsule Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
Capsule Specification. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .354
Capsule Specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 355
Capsule Specification - Diagrams Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356
Capsule Specification - Operations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356
Capsule Specification - Attributes Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357
Capsule Specification - Capsule Roles Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
Capsule Specification - Ports Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
Capsule Specification - Connectors Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
Capsule Specification - Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
Capsule Specification - Components Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
Capsule Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
15 Defining Protocols . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361
Protocol Specification. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .361
Protocol Specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
Protocol Specification - Signals Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
Protocol Specification - Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
Protocol Specification - Components Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
Protocol Specification - Diagrams Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 364
Protocol Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 364
Signal Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .364
Signal Specification - General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365
Signal Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365
16 Defining Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
Introduction to Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .367
Creating a Package . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .367
Packages and Class Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
Package Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .368
Package Specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369
Package Specification - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
Package Specification - Relations Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
Contents xix
Package Specification - Components Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
Package Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
Package Specification - Model Elements Tab. . . . . . . . . . . . . . . . . . . . . . . . . . 371
Moving Model Elements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .372
Impact of Moving Classes or Diagrams on Configuration Management . . . . . . . . . .375
17 Creating the Component and Deployment Views . . . . . . . . . . . . 377
Using the Component Diagram Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . .377
Component Diagram Toolbox. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .379
Using the Deployment Diagram Editor. . . . . . . . . . . . . . . . . . . . . . . . . . . . .380
Deployment Diagram Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381
Deployment Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .382
18 Importing and Exporting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
Importing a Petal or Package File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .385
Importing Code from Rational Rose to Rational Rose RealTime. . . . . . . . .385
Using the Code Import Process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
Preparing the Rational Rose Model for Import . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
Launching the C++ Analyzer. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 387
Specifying Export Options and Selecting a Source File Location . . . . . . . . . . . . . . . 388
Analyzing the Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .391
Using CodeCycle to Add Tags to Code. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
Importing the Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .394
Referencing an External Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .396
Using the Convert Rose Component Wizard . . . . . . . . . . . . . . . . . . . . . . . .397
Exporting a File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .399
19 Using Source Control. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
Fundamentals of Source Control in Rational Rose RealTime . . . . . . . . . . .401
Using Source Control in Rational Rose RealTime . . . . . . . . . . . . . . . . . . . .402
Maintaining Integrity When a Model is Under Source Control . . . . . . . . . . . . . 403
Source Control Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .404
Optimizing Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .408
Accessing Source Control Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .408
Source Control Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410
Adding Elements to Source Control. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .414
Performing an Unreserved Checkout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
xx Contents
Options for Obtaining Change Management Information When Loading a
Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .417
Updating the Log . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
Changing the CM Retrieval Option. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
CM Retrieval Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 420
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421
Checking Out Files When a Newer Version Exists. . . . . . . . . . . . . . . . . . . .422
Get Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .422
Controlling a Unit with an Uncontrolled Parent. . . . . . . . . . . . . . . . . . . . . . .425
Changing Unit Ownership . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
Viewing the ClearCase Version Tree for a VOB . . . . . . . . . . . . . . . . . . . . . .426
20 Naming Guidelines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 429
Introduction to Naming Guidelines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .429
Assigning Names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .429
Special Case Notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .430
Using Logical Names for Model Elements . . . . . . . . . . . . . . . . . . . . . . . . . .430
Logical Name Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 432
21 Building and Executing Models. . . . . . . . . . . . . . . . . . . . . . . . . . . 437
Building and Running Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .437
Is Rational Rose RealTime a Compiler? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
Real-Time Services (Services Library) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
Before You Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .438
Building . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 439
Executing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 439
Building Basics. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .439
Top-level Capsule . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 440
Assigning an Active Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .440
Creating a Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .441
Starting a Build. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .441
Generate Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .442
Unable to Compile a Component? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .443
Reviewing Build Results. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .444
Contents xxi
Opening Code Generated for Model Elements . . . . . . . . . . . . . . . . . . . . . .445
Selecting Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 445
Selecting a Single Element . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .445
Selecting Multiple Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 447
Using an Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 447
Build Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .447
Build Settings Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .450
Active Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450
Active Component Instances List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450
Build Log Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .450
Build Errors Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .451
Unknown Compiler Message Stream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 451
Component Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .451
Specification Content . . . . . . . . . . . . . . . . . . . . ...... ....... ...... ..... 451
Component Specification - General Tab . . . . . . ...... ....... ...... ..... 452
Component Specification - References Tab . . . ...... ....... ...... ..... 452
Component Specification - Relations Tab. . . . . ...... ....... ...... ..... 453
Component Specification - Files Tab . . . . . . . . ...... ....... ...... ..... 453
Generating Documentation Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .453
Using Generated Documentation Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 457
Component Dependencies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .461
22 Common Build Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463
Understanding Build Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .463
Missing Class Dependencies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
Capsule Role Name Same as Capsule Name . . . . . . . . . . . . . . . . . . . . . . . . . 464
Linking Wrong Services Library Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
Compiler Not Installed Correctly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
Compile a Simple Hello World Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
Check Environment Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
Review Your Compiler Flag Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
System Does Not Understand the Make Command. . . . . . . . . . . . . . . . . . . . . 465
Check Environment Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
Ensure that Component has Correct Make Types Configured . . . . . . . . . . . . . . . . . 465
Name Conflicts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466
Missing Header Files, Object Files, and Libraries . . . . . . . . . . . . . . . . . . . . . . 466
Compile Fails on Valid C++ Models with VC++ 5.0 or VC++ 6.0 . . . . . . . . . . . 467
Error Linking Capsule - Error From nmake . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
xxii Contents
Windows NT Compilation Command Line Limits . . . . . . . . . . . . . . . . . . . . . . . 467
Source File Compilation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
Linking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 468
Model Management - Importing Model Compilation Results . . . . . . . . . . . .468
Build Log Tab - Saving and Importing Compilation Results . . . . . . . . . . . . . . . 468
Saving the Build Output to a File Directly from the Build Log Tab . . . . . . . . . . 468
Importing from the Build Log Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 470
Build Errors Tab - Importing Compilation Results . . . . . . . . . . . . . . . . . . . . . . 471
23 Running and Debugging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 475
Execution Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .476
Creating a Component Instance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .476
Running a Component Instance with Purify . . . . . . . . . . . . . . . . . . . . . . . . .477
Interpreting the Purify Log Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 479
Running a Component Instance without Purify . . . . . . . . . . . . . . . . . . . . . .479
Observing a Running Component Instance . . . . . . . . . . . . . . . . . . . . . . . . .481
Rational Rose RealTime Execution Interface. . . . . . . . . . . . . . . . . . . . . . . .482
Target Control Programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
Overriding Target Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
Observability Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
Overview of Observability Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .483
Component Instance Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .484
RTS Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .485
Execution Control and Information Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
Capsule Instance Folder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 487
Probes Folder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 487
Monitors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .488
Animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
Opening a Monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
Probes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
Navigating to Model Elements from Debug Monitors . . . . . . . . . . . . . . . . . .490
Trace Windows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .490
Deleting Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 491
Trace Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 491
Using Different Types of Traces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
Opening a Sequence Diagram. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
Creating a Sequence Diagram From a Trace. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
Contents xxiii
Probes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .493
Inject Window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .494
Capsule Instance Trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .494
Trace Event Message Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
Creating a Sequence Diagram From a Message Trace . . . . . . . . . . . . . . . . . . . . . . 495
Dragging Capsule Instances into a Trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .495
Message Trace Configuration Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .496
Threshold Field . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496
Column Check Boxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496
Execution Watch Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .496
Refreshing the Watch Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497
Run-time Exception While Running a Component Instance . . . . . . . . . . . .497
Instance Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .498
Source Code Debugging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .498
Source Debugger Integration without Target Observability . . . . . . . . . . . . .500
Setting Breakpoints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .500
Setting Breakpoints on State Machines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 501
Setting Breakpoints for Operations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 507
Customizing Rational Rose RealTime for Target Control and Observability 507
Running from Outside the Toolset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .508
Purify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 508
Observability Command Line Parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 508
Component Instance Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .509
Using the Command Line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .509
Command Line Arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 509
Application-Specific Command Line Arguments . . . . . . . . . . . . . . . . . . . . . . . 510
Loading and Running Component Instances on Embedded Targets. . . . . .510
Utility Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 511
Component Instance Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .511
Component Instance Specification - General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . .511
Component Instance Specification - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . 512
Overview of Observability Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .514
Observability Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 515
xxiv Contents
Processor Specification Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .516
Processor specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516
Processor Specification - Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516
Using Windows CE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 517
Using Debugger Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521
Unloading a Debugger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 525
Device Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .525
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 525
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526
Connection Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .526
General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526
Detail Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 527
Files Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 527
Probe Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .527
Probe Specification - General Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 527
Probe Specification - Files Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 528
Probe Specification - Detail Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 528
Creating Inject Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 528
Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 529
Injecting a Message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 530
24 Using Code Sync to Change Generated Code . . . . . . . . . . . . . . . 531
Code Sync Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .531
Intended Code Sync Usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .532
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 532
Enabling and Disabling Code Sync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .533
Identifying Code Sync Areas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .533
Code Sync Identification Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 533
Designated Code Sync Areas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 534
Compiling Code Externally. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .535
Invoking Code Sync from the Toolset. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .535
Reconciling Changes in the Code Sync Summary . . . . . . . . . . . . . . . . . . .535
Accepting Changes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 536
Common Code Sync Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .536
Error: Cannot code-sync; file I/O error on: <filename> . . . . . . . . . . . . . . . . . . . . . . 537
Error: Cannot code-sync <filename> beyond line <lineNum> . . . . . . . . . . . . . . . . . 537
Error: Could not find trailing CodeSync tag for
[ <LocationSpecifier> ]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 537
Warning: Use tabs for indenting code-sync regions . . . . . . . . . . . . . . . . . . . . . . . . 537
Contents xxv
25 Generating Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 539
Linking External Files to Model Elements . . . . . . . . . . . . . . . . . . . . . . . . . .539
Generate Documentation Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .540
Inserting a Diagram into an MS Word Document. . . . . . . . . . . . . . . . . . . . .541
Option A . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .541
Option B . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .541
Using OLE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .542
Creating a Link . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542
Inserting a Link . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542
Navigating. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542
Editing Diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542
26 Customizing the Toolset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543
Stereotypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .543
Creating a Custom Framework for Rose RealTime Models . . . . . . . . . . . . . . . 543
Creating a New Stereotype for the Current Model . . . . . . . . . . . . . . . . . . . . . . 544
Creating a New Stereotype Configuration File . . . . . . . . . . . . . . . . . . . . . . . . . 545
Creating a New Stereotype for all Rose RealTime Models . . . . . . . . . . . . . . . 545
Creating Stereotypes for Classes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 548
Adding Stereotypes to the Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . 548
Creating Stereotype Icons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 548
Creating a Diagram Icon. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549
Controlling the Display of Stereotypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549
Controlling Stereotype Display in the Browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549
Controlling How Existing Stereotypes Display in a Diagram . . . . . . . . . . . . . . . . . . . 549
Controlling the Display of Stereotypes Added to Diagrams . . . . . . . . . . . . . . . . . . . 550
Toolset Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .550
Options Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 550
General Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 551
File Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 552
Font/Color Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 554
Diagram Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 555
Filtering Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 558
Compartments Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 558
Browser Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
Editor Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
THIDC_AA1oolbars Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .560
Language/Environment Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 560
Customizing the Diagram Toolbox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
xxvi Contents
Customize Toolbar Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
Toolbar Button List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
Add-In Manager Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .561
Managing Model Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .562
Displaying or Modifying the Values of Model Properties . . . . . . . . . . . . . . . . . 562
Removing an Overriding Item Level Model Property . . . . . . . . . . . . . . . . . . . . 563
Making a Model Property Item Specific . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 563
Reinstalling the State and Value of the Last Committed Change . . . . . . . . . . 563
Attaching a Model Property Set to a Single Element or a Collection of Elements .
563
Displaying or Editing a Specific Model Property Set . . . . . . . . . . . . . . . . . . . . 564
Creating a New Model Property Set. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 564
Deleting a Model Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 564
Index. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 573
Contents xxvii
xxviii Contents
Preface
This guide describes the Graphical User Interface for the Rational Rose RealTime
toolset. This guide is organized as follows:
■
Using the Online Help on page 1
■
Overview of Rational Rose RealTime on page 17
■
User Interface Overview on page 29
■
Other Application Windows on page 109
■
Printing on page 119
■
Opening and Saving Models on page 125
■
Use Case Diagrams on page 137
■ Defining Use Cases and Actors on page 141
■
Creating Class Diagrams on page 145
■
Creating Collaboration Diagrams on page 207
■
Creating State Diagrams on page 229
■
Creating Activity Diagrams on page 257
■
Creating Sequence Diagrams on page 299
■ Defining Capsules and Classes on page 333
■
Defining Protocols on page 361
■
Defining Packages on page 367
■
Creating the Component and Deployment Views on page 377
■
Importing and Exporting on page 385
■
Using Source Control on page 401
■ Naming Guidelines on page 429
■
Building and Executing Models on page 437
■ Common Build Errors on page 463
■ Running and Debugging on page 475
■
Using Code Sync to Change Generated Code on page 531
■
Generating Documentation on page 539
■
Customizing the Toolset on page 543
■ Keyboard Shortcuts on page 565
xxvii
Audience
This guide is intended for all readers including managers, project leaders, analysts,
developers, and testers.
This guide is specifically designed for software development professionals familiar
with the target environment they intend to port to.
Other Resources
■
Online Help is available for Rational Rose RealTime.
Select an option from the Help menu.
All manuals are available online, either in HTML or PDF format. To access the
online manuals, click Rational Rose RealTime Documentation from the Start menu.
■
To send feedback about documentation for Rational products, please send e-mail
to [email protected].
■ For more information about Rational Software technical publications, see:
http://www.rational.com/documentation.
■
For more information on training opportunities, see the Rational University Web
site: http://www.rational.com/university.
■
For articles, discussion forums, and Web-based training courses on developing
software with Rational Suite products, join the Rational Developer Network by
selecting Start > Programs > Rational Suite > Logon to the Rational Developer Network.
xxviii Preface
Rational Rose RealTime Integrations With Other Rational
Products
Rose RealTime– You can archive Rose RT ■ Toolset Guide: Rational Rose
ClearCase components in ClearCase. RealTime
■
Guide to Team Development:
Rational Rose RealTime
Rose RealTime– When linking or running a Rose ■ Rational Rose RealTime Help
Purify RealTime model with Purify ■
Toolset Guide: Rational Rose
installed on the system, developers
RealTime
can invoke the Purify executable
using the Build > Run with Purify ■
Installation Guide: Rational Rose
command. While the model RealTime
executes and when it completes, the
integration displays a report in a
Purify Tab in RoseRealTime.
Rose RealTime– You can associate RequisitePro ■ Addins, Tools, and Wizards
RequisitePro requirements and documents with Reference: Rational Rose RealTime
Rose RealTime elements. ■
Using RequisitePro
■ Installation Guide: Rational
Rose RealTime
Rose RealTime– You can create reports that extract ■ Installation Guide: Rational Rose
SoDa information from a Rose RealTime RealTime
model. ■ Rational SoDA User’s Guide
■ SoDA Help
Note: When you contact Rational Customer Support, please be prepared to supply the
following information:
■ Your name, company name, telephone number, and e-mail address
■ Your operating system, version number, and any service packs or patches you
have applied
■ Product name and release number
■ Your Service Request number (SR#) if you are following up on a previously
reported problem
When sending email concerning a previously-reported problem, please include in the
subject field: "[SR#XXXXX]", where XXXXX is the Service Request number of the
issue. For example, "[SR#0176528] - New data on rational rose realtime install issue ".
xxx Preface
Using the Online Help
1
Contents
This chapter is organized as follows:
■
Using the Online Help System on page 1
■
Using the Help Viewer on page 2
■
About the Search Tab on page 9
■
Changing the Help Viewer on page 14
■
Related Documentation on page 16
1
Extended Help is based on a set of databases that identify the context for the
information (called the target). After you instal, you have access to the RUP database.
You can create and register any number of databases, each containing different
information and pointers to different HTML pages. For example, you may have a
database that contains pointers to pages that are appropriate for all projects in your
organization. You may have another that is specific to a project or project type. You
can also create a personal database with pointers to information that is important to
you.
Tutorials
The online help includes tutorials to help you learn to use the main features of
Rational Rose RealTime.
Notes
Click on a contents entry, index entry, or search results entry to display the
corresponding topic.
Notes
■ To return to a favorite topic, click the Favorites tab, select the topic, and then click
Display.
■
If you want to rename a topic, select the topic, and then type a new name in the
Current topic box.
■
To remove a favorite topic, select the topic and then click Remove.
Notes
If you want to copy only part of a topic, select the text you want to copy, right-click,
and then click Copy.
Notes
If you print from the Contents tab (by right-clicking an entry, and then clicking Print)
you will see options to print only the current topic, or the current topic and all of its
subtopics.
Notes
■ To close the pop-up window, click anywhere on the screen.
■
If the dialog does not have the question mark, click Help or press F1.
■
You can also obtain help on an item by right-clicking it.
■
Not all dialog boxes include dialog-level help.
Notes
The toolbar in your Help Viewer may not contain all of these navigational buttons.
Notes
If you close the Help Viewer with the Navigation pane hidden, it appears minimized
the next time you open the Help Viewer.
To Press
Switch between the Help Viewer and other open windows. ALT+TAB
Change Microsoft Internet Explorer settings. The Internet ALT+O, and then press I
Options dialog box contains accessibility settings. To
change these settings click the General tab, and then click
Accessibility.
Move forward to the next topic (provided you have viewed ALT+RIGHT ARROW, or
it just previously). ALT+O, and then press F
Refresh the topic that appears in the Topic pane (this is F5, or ALT+O, and then press
useful if you have linked to a Web page). R
Return to the home page (help authors can specify a home ALT+O, and then press H
page for a help system).
Stop the viewer from opening a page (this is also useful if ALT+O, and then press S
you are linking to the Web and want to stop a page from
downloading).
Scroll through all the links in a topic or through all the TAB
options on a Navigation pane tab.
To Press
Open and close a book or folder. PLUS SIGN and MINUS SIGN, or LEFT ARROW and
RIGHT ARROW
To Press
Type a keyword to search for. ALT+W, and then type the word
To Press
Type a keyword to search for. ALT+W, and then type the word
To Press
Select a topic in the Favorites list. ALT+P, and then UP ARROW and
DOWN ARROW
Notes
■
You can also access context menu commands using the keyboard.
■
Shortcut keys also work in secondary and pop-up windows.
■
If you use a shortcut key in the Navigation pane, you lose focus in the Topic pane.
To return to the Topic pane, press F6.
■
The Match similar words box on the Search tab is selected if you used it for your
last search.
Command Description
Right-click in the table of Opens all books or folders in the table of contents. This
contents, and then click command only works if the Contents tab is displayed.
Open All.
Right-click in the table of Closes all books or folders. This command only works if the
contents, and then click Contents tab is displayed.
Close All.
Right-click in the table of Opens the Customize Information wizard, which allows
contents, and then click you to customize the documentation. If the help file was built
Customize with information types, you can use this wizard to select a
subset of topics to view. For example, you could choose to see
only overview topics.
Notes
■
You can click SHIFT+F10 to display the context menu, and then click the
appropriate shortcut keys, or you can enable Mousekeys. Use a Mousekey
combination to display the context menu, and then click the appropriate shortcut
keys.
Notes
■
To disable this option, click Options on the toolbar, and then click
Search Highlight Off.
■ When viewing a long topic, only the first five hundred instances of a search word
or phrase are highlighted.
Notes
When searching for a file name with an extension, group the entire string in double
quotation marks, for example, use "filename.ext". Otherwise, the period is interpreted
as a separation character and the search will attempt to find two separate terms. The
default operation between terms is AND, so the search uses the logical equivalent to
"filename AND ext."
Notes
■
You can precisely define a search by using wildcard expressions, nested
expressions, and boolean operators.
■
You can request similar word matches, search only the topic titles, or search the
results of a previous search.
■ You can set the Help Viewer to highlight all instances of search terms that are
found in topic files. Click Options, and then click Search Highlight On. This
feature only works with Internet Explorer 4.0 or later.
A single word select Topics that contain the word "select". (You will also find its
grammatical variations, such as "selector" and "selection".)
A phrase "new operator" Topics that contain the literal phrase "new operator" and all
or its grammatical variations.
new operator Without the quotation marks, the query is equivalent to
specifying "new AND operator", which will find topics
containing both of the individual words, instead of the
phrase.
Wildcard esc* Topics that contain the terms "ESC", "escape", and
expressions or "escalation". The asterisk cannot be the only character in the
80?86 term.
Topics that contain the terms "80186", "80286", "80386", and so
on. The question mark cannot be the only character in the
term.
Both terms in the same dib AND palette Topics containing both the words "dib" and
topic. "palette."
Either term in a topic. raster OR vector Topics containing either the word "raster" or
the word "vector" or both.
The first term without ole NOT dde Topics containing the word "OLE" but not
the second term. the word "DDE."
Both terms in the same user NEAR kernel Topics containing the word "user" within
topic, close together. eight words of the word "kernel."
Notes
■
The "|", "&", and "!" characters do not work as boolean operators (you must use
OR, AND, and NOT).
Notes
■
All HTML topic files are searched, including any that are not listed in the Contents
tab.
Notes
■
This feature only locates variations of the word with common suffixes. For
example, a search on the word "add" finds "added," but it will not find "additive."
Notes
■ To search through all of the files in a Help system, ensure that you clear this
option.
■ The Search tab opens with the Search previous results options selected if you
previously used this feature.
Notes
■
The Help Viewer will appear with the last size and position settings you specified
when it is opened again.
Notes
■
These changes do not apply to the Navigation pane or toolbar of the Help Viewer.
■
This will also change your accessibility settings for Internet Explorer 4.0.
Notes
■
These changes do not apply to the Navigation pane or toolbar of the Help Viewer.
■
This setting also changes your font settings for Internet Explorer.
Notes
■ These changes do not apply to the Navigation pane or toolbar of the Help Viewer.
■ This setting also changes your color settings for Internet Explorer 4.0.
Related Documentation
The following documents are related to the Rational Rose RealTime Toolset Guide:
■
Installation Guide, Rational Rose RealTime
■ Modeling Language Guide, Rational Rose RealTime
■
Guide to Team Development Guide, Rational Rose RealTime
17
Rational Rose RealTime includes features for:
■ Creating UML models using the elements and diagrams defined in the UML
■
Generating complete code implementations (applications) for those models
■
Executing, testing and debugging models at the modeling language level using
visual observation tools
■
Using Change Management systems for team development
Compiling Models
You compile models generated from Rational Rose RealTime using commercial
compilers and linkers. Rational Rose RealTime generates the code, and then calls the
specified compiler and linker to compile and link the generated source code with the
pre-compiled Services Library.
Note: Rational Rose RealTime does not include a compiler or linker. You must first
install a compiler and linker before you can build and run a model.
Capsules
■ A capsule is a stereotype of a class.
Has much of the same properties as regular classes with added semantics for
modeling of communication relationships between capsules and modeling of its
event based behavior using a state diagram.
■ Provides built-in support for light weight concurrent objects.
Because of the message based nature and high encapsulation of capsules, they can
be easily distributed to different physical threads of control without any change to
the capsule.
■
Highly encapsulated objects using message based communication to other
capsules via its port objects.
The advantage of the message-based interfaces is that a capsule has no knowledge
of its environment outside of these interfaces, making it a much more
distributable, reusable, and robust than regular objects.
■
Capsule can aggregate other capsules.
Like classes, a capsules structure is defined by its attributes (encapsulation of
objects of other types of classes). But it can also be defined by attributes that are
other capsules, which we call capsule roles.
Protocols
■
Defines the set of messages exchanged between a set of capsules.
■
Messages are defined from the perspective of both the receiver and the sender.
There are therefore different perspectives of a protocol, which we call protocol
roles. Protocol roles represent the communication from the perspective of one
participant in the communication scenario.
■ Messages that are sent between capsules contain a required signal name (which
identifies the message), an optional priority (relative importance of this message
compared to other unprocessed messages on the same thread), and optional
application data.
State Diagrams
■ Uses the same notation as defined in the UML.
■
Are generated to source code and make up the behavior of capsules.
■
All trigger events are defined by a port and signal pair. A capsule’s behavior is
therefore based on the receipt of messages.
■
Final states are not allowed on capsule state diagrams.
■
Junction points do not support the continuation kind attribute; that is, if a
transition is not continued, it defaults to history (except for internal transitions).
Executable Models
The addition of the capsule and the formal semantics surrounding the capsule
structure allows Rational Rose RealTime to generate, compile and run a complete
implementation based on a model containing capsules.
The ability to execute models has a revolutionary impact on the software
development process. The results are higher quality software, and shorter and more
predictable delivery cycles. Executing models is the surest way to find problems and
issues that whiteboarding and document reviews do not find. Even high-level
architectural models can be executed.
Modeling Elements
There are many different modeling elements supported in Rational Rose RealTime,
and it is not easy for new users to know which elements to use to accomplish their
goals. In practice, there are only a few elements that are required to construct a
running model. The other elements provide greater flexibility and control over the
expression of your design model.
As you have already seen from the overview description of the Rational Rose
RealTime services library, the services library is essentially a framework for executing
capsules. Capsules are the main initiators and controllers of activity in a Rational Rose
RealTime model. You must define at least one capsule, but typically many more, in
order to generate and compile code for the model. The capsules in the model should
contain other classes, usually referred to as data classes, because they must be
invoked from a capsule behavior before they can perform any action. Also, they are
primarily used by capsules to contain detail data, which is operated on within the
capsule.
Required Elements
First of all, there are two elements that most developers will make use of at the start of
a project to understand the problem domain and begin the process of turning the
vague problem descriptions into detailed designs and implementations. These two
elements are use cases and actors. They are used together (along with use case
diagrams) for use case modeling, which helps architects, designers, testers, and others
Further Reading
These are all the model elements that are required in order to create an executable
model in Rational Rose RealTime. Each of the possible elements in the model is
described further in the Modeling Language Guide.
Development Process
The Rational Rose RealTime toolset is oriented to the use of an iterative,
object-oriented development process. However, detailed description of the
development process is beyond the scope of this document. We strongly recommend
that you look at the Rational Unified Process (RUP) to gain a better understanding of
the iterative object-oriented development process. See http://www.rational.com. At a
more detailed level, the process of creating an executable model in Rational Rose
RealTime can be summarized as follows:
Use the use case modeling elements and use case diagram to develop a detailed,
semi-formal understanding of the problem. The use case elements can be associated
with design elements as the design model evolves to maintain traceability.
Create capsules, protocols, classes, use class diagrams, capsule structure diagrams,
and capsule state diagrams to develop the structure and behavior of the model. Add
detailed implementation code to the capsule state diagrams and to class operations.
In addition, use collaboration diagrams and sequence diagrams to capture the
intended behavior of the system for various use cases. Use Rational Rose RealTime's
execution and debugging tools to validate the model behavior at run-time. Use
collaboration and sequence diagrams to help you in the design process by making the
communication patterns in the design evident. They will also help others understand
your design.
Once the design has stabilized, use state diagrams for classes and protocols to capture
the abstract design so that others can understand. This is particularly important for
protocols, where the state machine specifies how a capsule using that protocol must
behave.
Use the component diagram to specify the configuration of the model for compilation
purposes.
Use the deployment diagram to indicate how the components should be executed.
Also, the deployment diagram can be used to document the physical structure of the
target system.
Development Process 25
Further Reading
An overview of the Rational Unified Process is available in the Online Help book:
Development process reference. The complete Rational Unified Process description is
available at http://www.rational.com.
Essential Workflows
The following chart describes the workflows and project phases defined in the
Rational Unified Process.
Rational Rose RealTime is not applicable to all of these workflows. The following
workflows are important in the context of Rational Rose RealTime:
Requirements - are typically captured in text documents or databases outside of the
Rational Rose RealTime toolset. Some analysis of the requirements is performed to
develop a more abstract model of the problem. The abstract model is called a use case
model. The Rational Rose RealTime use case modeling tools are used in this worklow.
In addition, design model elements can be traced back to requirements in two ways:
through associations between use case model elements and design model elements
captured in class diagrams, and through linking external files (requirements
specifications, for example) to model elements.
Analysis & Design - is the primary workflow supported in the Rational Rose
RealTime toolset. All of the Rational Rose RealTime class and capsule modeling tools
are used in the analysis and design. There is no clear distinction between analysis and
design in the Rational Rose RealTime toolset. They are part of the same process, which
is the process of turning vague problem descriptions into specifications of
software-based solutions. The end goal of this process is a design model, which in
Further Reading
Each of these workflows and the impact of the tools in Rational Rose RealTime on
those workflows is described in the Online Help.
Essential Workflows 27
28 Chapter 2 - Overview of Rational Rose RealTime
User Interface Overview
3
Contents
This chapter is organized as follows:
■
Startup Screen on page 29
■
Create New Model Dialog on page 30
■
Application Window on page 37
■
The Toolbar on page 39
■
Menus on page 43
■
Browsers on page 78
■
Diagram Editors on page 82
■ Specification Dialogs on page 92
■
Searching and Sorting on page 104
Startup Screen
The Startup screen has direct links to:
■
What’s New? - To review the new features of this release of Rational Rose
RealTime
■
Tutorials - To review various tutorials tailored to your skill level and backgrounds
■
Online Help - To access the Rational Rose RealTime help system
You have the option of always showing this screen on startup or bypassing it.
29
Create New Model Dialog
When you start Rational Rose RealTime, the Create New Model dialog appears.
In the Create New Model dialog, you have the following frameworks available:
■
Empty - Lets you to open a model without any shared package, which is useful for
pure modeling and use case development. The Empty framework allows the you
to open a model without any shared packages that provide language-specific
Runtime Services.
Note: The Empty framework is useful for creating use case designs but should not
be used for developing real-time applications.
■
RTC - Lets you to create a model in the C language. The RTC framework contains
all the Runtime Services classes needed for development of a Rational Rose
RealTime model using the C language.
■ RTC++ - Lets you to create a model in the C++ language. The RTC++ framework
contains all the Runtime Services classes needed for development of a Rational
Rose RealTime model using the C++ language.
The simplest Hello World example is implemented by the class HelloWorldClass. The
class and the capsule depend on stdio.
Note: The external file has been modeled to make it visible in the design.
Figure 3 shows the Operation Specification dialog for the main function for the
HelloWorldClass class.
The generated code for the main operation will look like the following:
int main( int argc, const char * argv )
{
printf ("Hello World from C++ main\n");
getchar();
return 0;
}
Figure 4 shows the Component View for this Hello World startup model. The
Component diagram describes the build structure.
To generate the corresponding code, right click on the component in the diagram or in
the model browser and click Build > Build, and then select Generate and Compile.
Note: Before you build, you will need to open the Specification dialog for the
component and configure it for your compiler.
You can run the generated executable from the command-line, or you can start it from
within the modeling environment. To run the executable, from the Deployment View
on the Model View tab in the browser, right-click on the component instance called
HelloWorldExeInstance, and click Run.
Figure 5 shows the results that appear in the console when you run the class-based
executable.
In the capsule-based model, the code is in the initial transition of the state machine.
You can inspect the code on the State diagram using the Code tab, or by opening the
Transition Specification dialog.
Browsers
Model elements are created and viewed through browsers. The primary tab in the
browser is the Model View tab, that provides access to all elements of the current
model. Browsers list the model elements - usually in a hierarchical way - allowing
elements to be expanded to show additional information. Also, most browser lists can
be filtered in various ways.
Application Window 37
The Containment View shows the containment hierarchy of the capsule classes in the
model.
The Inheritance View shows the inheritance hierarchy of the capsule classes, data
classes, and protocols in the model.
Toolbar
There is a standard toolbar (see The Toolbar on page 39) in the main application
window that contains icons for a standard set of tools, which can be invoked at any
time. This toolbar can be undocked and moved as a separate window.
Diagrams
Much of the model information is captured graphically in Diagram Editors.
Additional non-graphical information, such as detailed program code, can be entered
through Specification Dialogs. In many cases, information can be entered through a
diagram or specification dialog, or Code window.
Each diagram or specification that you open is displayed in a window within the
application window. These diagram and specification windows can be iconified. If the
active window displays a diagram, that diagram is referred to as the current diagram.
If the active window displays a specification, that specification is referred to as the
current specification.
Toolboxes
Every diagram has an associated toolbox (see Toolboxes on page 91), that contains
icons of tools that can be applied to that diagram. If the current diagram is
write-protected, the diagram toolbox is not displayed. The diagram toolbox is
dimmed when a diagram is displayed.
Menu Bar
The menu bar lists commands available for operations in any diagram or specification
window. Depending on the kind of diagram or specification displayed in the active
window, some menu commands may not apply. These commands are dimmed. If the
current diagram is write-protected, additional commands are rendered inaccessible.
The Toolbar
The standard toolbar is displayed directly below the menu bar along the top of the
application window. The visibility of the toolbar is set through the View menu. By
default, the standard toolbar is displayed. If you want to disable the standard toolbar
from the application window, select View > Toolbars > Standard. This switches the
visibility property of the toolbar.
The Toolbar 39
Open Existing Model
Opens the Load Model dialog. If you have a model open when you select the open
model, you are asked if you want to save the current model. Selecting No discards all
changes since your last save. Selecting Yes saves your changes and opens a new
model. See Opening Models on page 129 for more information.
Save Model
Opens the Save Model to dialog. Enter a new filename. After the model is named and
saved, selecting this button automatically saves your changes to the current model
without displaying the dialog.
Print Diagram
Opens the Print Specification dialog, that allows you to specify how and where
diagrams are printed. To change printer setup select File > Print Setup.
Cut
Removes icons or relationships from your model. An item (or items) must be selected
to activate the icon. Cutting an element also cuts associated relationships. You can cut
multiple-selected items.
Copy
Copies a component to a new location of the same model - or a new model - without
affecting the original component.
Paste
Pastes a component, that has previously been cut or copied to the clipboard, to
another location.
Undo
Undoes the last operation performed. Not all operations can be undone. If the Undo
tool is dimmed, the last operation cannot be undone.
Redo
Redoes the last operation that was undone.
Stop Build
Stops a build in progress.
Load Process
Loads the components instances specified in the Build Settings dialog. The
component must be successfully built before it can run.
If the Attach Target observability flag was set on the Component Instance
Specification dialog and a Target observability Port number filled in, the execution
interface is displayed allowing you to control the execution of the model.
View Browser(s)
Displays or hides all existing browsers. Existing browsers are those that have been
created, but not closed.
View Description
Displays the Description Window, that contains the Documentation Tab and the Code
Tab.
View Output
Displays the Output window.
The Toolbar 41
Browse Use Case Diagram
Opens a Use Case diagram in the Use Case diagram editor (see Using the Use Case
Diagram Editor on page 138). Selecting this command opens a dialog allowing you to
select from available use case diagrams to open.
Browse Parent
Displays the "parent" of the selected diagram or specification. If you have a
specification selected, the specification for the parent of the “named” item is
displayed.
Fit in Window
Centers and displays any diagram within the limits of the window. This command
changes the zoom factor so that the entire diagram displays.
Scale to Fit
Scales the diagram to fit within the current diagram window geometry.
Help Contents
Activates the online help system.
Menus
This section provides information on the following topics:
■
Menu Bar on page 44
■
File Menu on page 45
■
Edit Menu on page 49
■
Parts Menu on page 54
■ View Menu on page 56
■
Browse Menu on page 57
■
Build Menu on page 61
■
Report Menu on page 64
■
Query Menu on page 66
■
Tools Menu on page 68
■ Add-Ins Menu on page 75
■ Window Menu on page 76
■
Help Menu on page 77
Menus 43
Menu Bar
The menu bar provides drop-down menus for all operations on models and model
elements.
Some menu items are context-sensitive, and only operate when certain types of model
elements are selected. Context-sensitive menu items are grayed-out when they are not
applicable.
New
Opens the Create New Model dialog. There are four frameworks listed: Empty, RTC,
RTC++, and RTJava. Additionally, any framework model that you create to be used
as a template, appears in the dialog.
To create a new Rational Rose RealTime model containing all the classes required for
development for the C, C++, or Java language, click the framework for the specified
language. The Model browser appears with the packages and classes populated in the
Logical View and Component View.
For information on creating a framework, see Creating a Custom Framework for Rose
RealTime Models on page 543.
Note: The Empty framework is useful for creating use case designs but should not be
used for developing RealTime applications.
A new model is unnamed until it is saved by a Save or Save As command.
Any open models are closed before a new model is created. You are prompted to save
changes if necessary.
By default, a new model contains one empty class diagram - the main class diagram
for the top level of the new model. You should place packages and classes
representing your highest-level abstractions in this diagram. The new model is
automatically created as a controlled unit.
Open
Loads a model or model kernel from a model file. A file browser is opened to let you
to select a .rtmdl file. If there is an accompanying workspace (.rtwks) file, the tool asks
if you want to open it instead.
Any open models are closed before opening another model. You are prompted to save
changes if necessary.
If the selected model file's access control in the platform file system is read-only, the
application write-protects the associated model.
Menus 45
When opening the model, the tools checks whether the model’s saved character set is
the same as the current system default charSet. If not, a dialog displays the following
warning:
"Non system default character set in file."
See Opening Models on page 129.
Open Workspace...
Opens an existing workspace. A file browser is opened allowing you to select a .rtwks
file.
Save Workspace
Saves the workspace. This action creates four files: a .rtwks file containing
configuration management settings; a .rtmdl file containing the representation of the
model itself; a .rtto file containing Target observability items, including probes and
inject messages; and a .rtusr file containing various application settings.
Save Model
Saves the model. Writes the model out as a .rtmdl file. If the model has not been saved
before, a file browser is presented to specify the file name and location.
If a destination model file's access control in the platform file system is read-only, an
ERROR! dialog is displayed indicating the software cannot write that file.
To control temporary and backup files created during a Save procedure, refer to the
Customizing the Diagram Toolbox in the Tools > Options dialog.
Export Model...
Exports model files in alternative formats. Primarily used to exchange models with
other versions of Rational Rose and other Rational Rose tools.
This command displays the Write Petal dialog so that you can specify the name and
location of the petal file. Use this command to export selected items from the current
model to a petal file. The Export command displays the name of the element type
selected. If nothing is selected, Export Model is displayed. You can export:
■
The entire model
■
Classes
■
Logical Packages
■ Component Packages
Menus 47
Begin by displaying diagrams containing the items you want to export. Select the
specific classes, logical and component packages to be exported, and pull down the
File menu. The Export command indicates the number of items selected. If no items
are selected, the entire model is exported. If any item not on the above list (such as a
relationship or adornment) is selected, the Export command is not executable.
When a logical or component package is exported, all diagrams it contains are also
exported. When individual classes are exported, however, only their state transition
diagrams are exported with them. Exporting the entire model does export all
diagrams contained within it.
Exporting to a petal file is useful when you want to transfer:
■
elements from one model to another
■
a model or its elements between different computing platforms
■
a model or its elements to a new software release
Print...
Prints the model. Printing on page 119
Print Setup...
Changes the print setup before printing.
Recent Files
Opens recently edited models.
Recent Workspaces
Opens recently used workspaces.
Exit
Exits the application.
Undo
Undoes the last operation. Some operations may not be undone. If Undo is not
possible, the Undo menu item is grayed-out.
Redo
Redoes the last undone operation.
Cut
Removes the selected item and places it in the buffer. When you cut an item, all
relationships for that item are also cut. For example, if A is a generalization of B and
you cut A, the generalization is also cut.
This command works only on the graphic representation of a diagram. It does not
change the current model. Not all elements can be cut and pasted. If after selecting an
element or group of elements the Cut menu item is grayed-out, the cutting and
pasting of one or more of those elements is not supported; for example, you cannot
cut and paste multiple elements in a capsule state diagram.
Copy
Copies the selected item into the buffer. Use this command to copy the currently
selected item or items to the clipboard. From the clipboard, you can
■
paste items into other diagrams
■
paste items into documents you create with any standard word-processing
software
The Copy command provides a simple means of importing a class from one package
to another.
If a relationship is copied and your selection does not include the items at both ends of
that relationship, you cannot paste that relationship. In this circumstance a Warning
dialog appears, allowing you to cancel or continue. You can also disable subsequent
warnings for the remainder of your session.
This command works only on the graphic representation of a diagram. It does not
change the current model.
Paste
Pastes whatever is currently in the buffer into the selected destination (the active
window).
Menus 49
Delete
Deletes the currently selected item(s) from a diagram or specification.
When used in a Class diagram, the Delete command removes each selected icon from
the current diagram. The model is not changed unless the deleted icon is unnamed.
In the structure and behavior diagrams of a capsule, delete always deletes the model
object.
When you delete an item, all relationships associated with that item are also deleted.
In collaboration and interaction diagrams, you are prevented from deleting an icon
representing a component or relationship if there are no other icons representing that
component or relationship in the active diagram. In a collaboration diagram, you are
prevented from deleting an icon representing an object if that object has one or more
links, and you are prevented from deleting a link if that link has one or more
messages. In all of these cases, you can use the Delete from Model command.
Duplicate
Duplicates a selected model item into the package that owns the diagram and
validates its name in the context.
Select All
Selects all elements on the current diagram or all text in the current editor.
This command is useful when you want to:
■
Generate reports on all the classes in a single diagram using commands on the
Report menu
■
Populate a class diagram with all of the information about those classes using
commands on the Query menu
■
Change the font size or characteristics for all of the text in a diagram using
commands on the Options menu
To deselect all items, click at a point on the diagram that is not already highlighted.
Note: The following two items are only available from Sequence diagrams.
Relocate
As the analysis and design of an application proceeds, it is common to refine the
application's logical and/or physical architecture from one iteration to the next. Such
refinements can include:
■
Relocating a class or logical package from one logical package to another
■
Relocating a component or component package from one component package to
another
The Relocate command supports these refinements. It allows you to relocate a model
element (class, component, package, or association) to a new logical or component
package.
The component will now be contained by the component package containing the
current diagram. However, relocating a component or component package has no
effect on any diagram in the model.
Line Attributes...
Lets you select between rectilinear or oblique line styles, and routing styles. You can
undo and redo any changes you make. Select Line Attributes > Edit... to edit the
properties of line attributes.
Find...
Finds all references to a specified item in the model.
Menus 51
Figure 12 Find in Model Dialog
The Find in Model dialog provides a drop-down list of your previous search strings,
if any. Select an existing search string or specify the search string to find. The search
results appear in the Find tab of the Output window (click View > Output)
Note: You can select Output to Find 2 pane on the Find in Model dialog to display
the search results in the Find 2 tab.
To search for groups of items or to search code, you can use the wildcard
character (*):
■
A* matches any name beginning with the letter A
■
*A matches any name ending with the letter A
■ *A* matches any name containing the letter A
This command lists only the first 250 items that match a name containing a wildcard
character. To search for “*”, use “\*”.
The * wildcard is especially useful for finding any classes or packages that were
automatically renamed in a model that was upgraded from a previous release. For
example, you can search for every model item that was renamed by typing: *#* (star
pound star). Every model item that has a # in its name is found.
This command searches for the named item and displays a list of diagrams in which
that item appears. You can double-click on an entry to display that diagram.
Reassign...
Each icon in a diagram represents an element in the current model. Use this command
to make a selected icon represent a model element other than the one it now
represents. For example, you can assign an existing class to a different diagram
element.
This feature is useful if you want to assign an element to use the same named item
from a different name space.
To make an icon represent another element, select the icon and then click Reassign
from the Edit menu. The dialog lists the packages in the model on the left and a list of
the valid elements to choose from on the right. Choose the model element that the
selected icon will represent. This affects only the selected icon. Other icons
representing the original model element (on all diagrams) maintain their original
representation.
Here is an example: Assume you have three classes named car, buggy and wagon.
With buggy selected, click Edit > Reassign. In the dialog select wagon. You are
changing the underlying model of the diagram element buggy to use wagon instead
of buggy. (Buggy may still exist in the model but you are given the option of deleting
it.) Additionally, if buggy had an inheritance relation drawn to car, then wagon adopts
that inheritance relation.
The Reassign command does not work within Capsule Collaboration (Structure)
diagrams.
Compartment...
Opens the Edits Compartments dialog. This dialog allows you to arrange how
attributes and operations are displayed within a class or package icon on a diagram.
Menus 53
Change Into
Changes the selected model element into another (related) kind of modeling element.
In the process of refining your model, you may find it necessary to change a model
element from one kind to another. For example, you may want to change a class into a
capsule once you have decided that the class has a state machine and a logical thread
of control.
You can use the commands on the Change Into submenu to change a model element
from one type to another. You can transform
■ A class into another type of class
■
A relationship into a different type of relationship
You can also transform an element as follows:
1 Choose the icon on the diagram toolbox.
2 Press the ALT or META key.
3 Click on the element you want to change.
This command changes the model element and updates all diagrams containing this
element.
When a relationship type is changed, this command removes the original relationship
from all diagrams, but does not automatically add the new relationship to these
diagrams. Use the Filter Relationships command to display the new relationship in
specific diagrams.
Parts Menu
Note: The Parts menu is only available on capsule structure and state diagrams.
Edit Inside
Shows the internal composition of a contained state or capsule role's class. Allows you
to perform edits (with some limitations) on elements contained inside the selected
state or capsule role without having to open a new editor. This is most useful for
seeing the internal connections of transitions to substates and of relay ports to other
contained capsule roles.
Inherit
Causes a previously excluded element to be reinherited. Reinherited elements are
added back to the diagram.
Aggregate
Applies only to states or capsule roles. For states, the aggregate command creates a
new composite state containing the selected states to be aggregated. For capsule roles,
the aggregate command creates a new capsule class to hold the capsule roles that are
being aggregated. This command also replaces the aggregated capsule roles in the
structure diagram where the command was executed with a single capsule role of the
newly-created capsule class.
Decompose
Applies only to composite states or capsule roles that are aggregates. Breaks the
selected state into its immediate substates, or breaks the selected capsule role into the
capsule roles contained within the aggregate capsule class.
Promote
Moves the selected element up in the class hierarchy. The element is moved into the
immediate superclass and is inherited by the subclasses (including the current class).
If there is any name conflict between this element and another element in the
superclass or in any of its subclasses, the promote command fails.
Demote
Moves the selected element down in the class hierarchy. The element is removed from
the current class, and is pushed down into all immediate subclasses, as if it had been
defined locally on the subclasses.
Menus 55
Lock Position(s)
Locks the element in position on the diagram. Once the element is locked it cannot be
moved around the diagram unless it is unlocked.
Unlock Position(s)
Allows the element to be moved around within the diagram.
View Menu
Toolbars
Toggles the display of the The Toolbar and Toolboxes.
Status Bar
Toggles the display of the status bar at the bottom of the window, which provides
textual information about selected items and current operations.
Browsers
Toggles the display of all application browsers, as well as create a new one.
Description
Toggles the display of the Description Window, which contains the Documentation
Tab and the Code Tab.
Output
Toggles the display of the output window.
Specification History
Records Specification dialogs opened from within toolset, allows you to easily
navigate between the dialogs, and provides a mechanism to quickly close these
dialogs.
Filter
Filters label information on diagrams.
Zoom
Zooms in on the current diagram. Select the zoom level.
Page Breaks
Toggles the visual indication of where page breaks appear on diagrams when printed.
The printer specified in the Printer Setup determines the exact location of page breaks.
You can also change this setting through the rose.ini file.
Refresh
Redraws the current diagram.
Browse Menu
Use commands on the Browse menu to navigate through the diagrams and
specifications that represent your model.
Using commands from the dialog, you can display, rename, create, and delete
diagrams.
Menus 57
Browse Menu Operations
Class Diagram...
Opens a Select Class Diagram dialog, allowing you to select a diagram to open, or to
create a new diagram. The dialog also allows you to rename or delete diagrams.
Collaboration Diagram...
Opens a Select Collaboration Diagram dialog, allowing you to select a diagram to
open, or to create a new diagram. The dialog also allows you to rename or delete
diagrams.
Sequence Diagram...
Opens a Select Sequence Diagram dialog, allowing you to select a diagram to open, or
to create a new diagram. The dialog also allows you to rename or delete diagrams.
Component Diagram...
Opens a Select Component Diagram dialog, allowing you to select a diagram to open,
or to create a new diagram. The dialog also allows you to rename or delete diagrams.
Deployment Diagram...
Opens a Select Deployment Diagram dialog, allowing you to select a diagram to open,
or to create a new diagram. The dialog also allows you to rename or delete diagrams.
State Diagram
This menu item is only activated when you have selected a capsule, class, or protocol
on a diagram. Use this command to display the state diagrams associated with the
selected class or protocol in a class diagram.
Structure Diagram
This menu item is only activated when you have selected a capsule on a diagram. This
operation opens a structure diagram for the selected capsule.
Open Subclasses
Displays a list of subclasses in a Choose Capsule Role Dialog. Only applies to
capsules. Selecting a capsule from the displayed subclass list and clicking OK opens
the corresponding diagram for the selected capsule. Only applies when the current
diagram is a capsule structure diagram or a state diagram (capsule, protocol, or data
class).
Go Inside
Replaces the current diagram window contents with the corresponding diagram for
the selected capsule role (for capsule structure diagrams) or substate (for capsule state
diagrams). For example, selecting a substate on a capsule state diagram and choosing
Browse > Go Inside causes the substate's state diagram to replace the current state
diagram in the same window. Only applies when the current diagram is a capsule
structure diagram or a state diagram (capsule, protocol, or data class).
Go Outside
Replaces the current diagram window contents with the corresponding diagram for
the selected capsule role (for capsule collaboration diagrams) or substate (for capsule
state diagrams). For example, selecting a substate on a capsule state diagram and
choosing Browse > Go Outside causes the substate's state diagram to replace the
current state diagram in the same window. Only applies when the current diagram is
a capsule structure diagram or a state diagram (capsule, protocol, or data class).
Expand
Opens the subdiagram associated with an item. Packages/subsystems have a default
main diagram that you can expand to if you select a package or a subsystem in
another diagram.
Parent
Selecting Browse > Parent or clicking the Browse Parent icon on the toolbar displays
the “parent” of the selected diagram or specification. If you have a specification
selected, the specification for the parent of the “named” item is displayed. For
example, if you select a substate selected in a state diagram, choosing Browse >Parent
opens a state diagram on the parent state from a substate.
Menus 59
Specification...
Opens the specification dialog for selected item(s) on the current diagram.
Top Level
Use this command to display:
■ the top level main class diagram
■
the top level main component diagram
■
the deployment diagram for your model
Previous Diagram
Brings to front or opens the last diagram that was current.
Build Menu
Build
Opens the Build dialog from which you can choose the Build Level.
Quick Build
Builds the component using the options you specified the last time you built this
component.
Rebuild
Forces a complete build of a component. All classes references by the component will
be verified, regenerated, compiled, and linked.
Clean
Removes all files from the output directory.
Menus 61
Stop Build
Stops the build in progress.
Run (F5)
Loads the component instances specified in the Build Settings Dialog. The component
must be successfully built before it can run.
If the Attach Target observability flag was set on the Component Instance
Specification dialog and a Target observability Port number filled in, the Target
observability interface is displayed allowing you to control the execution of the
model.
Note: The following four items only apply when a Target Observability session is
running.
Start (F5)
Starts the execution of the component instances. If the component instances are in the
reset state, execution begins with all fixed capsules being initialized (initial transitions
fired). If the component instances are in the stop state, execution resumes.
Stop (Shift+F5)
Stops the execution of the component instances at the current point of execution and
remembers the state of all capsules. Execution is stopped as soon as each currently
running transition is finished. The stop button does not halt execution in the middle
of a transition action.
Step (F10)
Steps through the next deliverable message. Pressing the step button while in the
stopped state causes the next message of the highest available priority to be delivered.
Any associated transitions are executed. Execution stops again as soon as the last
transition segment for that message has finished executing.
Restart (Ctrl+Shift+F5)
Resets the component instances, resetting all fixed and destroying all dynamic
capsule instances. The running component instance is terminated and a new one is
run.
Reload
Kills the existing model process and runs the model again. The execution interface
stays open.
Shutdown
Kills the existing model process and closes the execution interface.
Settings...
Displays the Build Settings Dialog. You must use this dialog to specify the active
component before you can build the component.
Component Wizard...
Activates the Component Wizard to help you through the steps of creating and
deploying a component.
Menus 63
Report Menu
Generates lists of diagrams in which the selected class is a supplier in a relationship,
or in which instances of the selected class appear. These lists can be used to navigate
to the diagrams they contain.
Show Usage...
Obtains a list of all the locations where the selected item is used (a supplier in a
relationship).
This command displays a list of diagrams in the Show Usage dialog. Double-click on
a diagram from the list to display the diagram.
Show References...
From a Use Case, Class or Structure diagram, will find any roles on colloboration
diagrams that reference the selected classifier.
Menus 65
Documentation Report
Generates a data dictionary from the model.
Query Menu
The Query menu provides commands that control which model elements appear in
the current diagram. Use case diagrams, class diagrams and component diagrams
support the Query menu functionality.
Add Classes...
Adds classes from the browser to the current diagram. Brings up a dialog with a list of
available classes to choose from. This menu item is only visible when a Use Case or
Class Diagram is open.
Add Capsules...
Adds capsule classes from the browser to the current diagram. Brings up a dialog
with a list of available capsule classes to choose from. This menu item is only visible
when a Use Case or Class Diagram is open.
Add Components...
Adds components from the browser to the current diagram. Brings up a dialog with a
list of available components to choose from. This menu item is only visible when a
Component Diagram is open.
Add Interfaces...
Adds classes from the browser to the current diagram. Brings up a dialog with a list of
available classes to choose from. This menu item is only visible when a Component
Diagram is open.
Menus 67
From the Expand Selected Elements dialog, you can display the Class Specification -
Relations Tab on page 344 for class diagrams or for component diagrams to specify
relationship-kind and access-kind criteria for choosing additional elements.
Note: The level cannot be changed if you select Expand indefinitely.
Filter Relationships
Displays the Relations tab from the class and use case diagrams, and the Visibility
Relations dialog from the component diagram. Both enable you to specify which
kinds of relationships can appear. The filter relationship dialog remembers the last set
of filter settings used. Use this command to control which kinds of relationships
appear in the current diagram.
Tools Menu
Layout
Opens a submenu of options for rearranging the diagram:
Layout Diagram
Analyzes the location of all icons in the current diagram, determines the optimal
location for the icons, and redraws the diagram.
Align/Distribute...
Opens the Align and Distribute dialog. The selected objects are arranged according to
the choices made in the dialog. Alignment and distribution operations can be
performed in both horizontal and vertical arrangements.
Autosize All
Resizes all the objects in the diagram to fit their labels. The size of the objects increase
or decrease to the minimum size required for the label to appear.
Menus 69
Reposition all from Superclass
Modifies the Structure and State diagrams for a capsule by repositioning the selected
item views according to their position in the superclass. Only the following items can
be repositioned:
■ State
■
Port
■
Capsule Role
■ Choice Point
■
Entry and Exit Point
■
Port Role
■
State Perimeter
■
Collaboration Perimeter
If any other items are selected, the will be ignored.
Note: This option attempts to position (from the superclass) all item views on a
diagram, including those that do not fully support this operation, such as non-linear
transitions.
Create
Opens a submenu of options for creating elements to place on the current diagram.
Use the commands on the Create menu to place the icons in the active diagram.
When you choose an item from the Create menu, the corresponding diagram toolbox
tool becomes active and the pointer changes to a cross (for a node) or an arrow (for a
relationship). You can then use the mouse to position the pointer and place the new
item.
The contents of the Create menu change to match the current diagram's toolbox.
Check Model
Provides a way of re-executing the model validation that happens at open time.
Check Model is designed to be used when you are saving your model to multiple
controlled units to ensure that all the units are consistent with one another. This is
especially useful when parallel development is going on in multiple controlled units,
since it is possible for different units to get out of sync with one another.
In a model, where one item holds a reference to another item, it is possible that a
reference exists, but there isn’t an item in the model of the right kind or with the right
name. In that instance, the reference is unresolved.
Import Code...
Opens a file browser allowing an external code file to be selected and imported. See
Importing Rational Rose Generated Code on page 136.
Model Properties
Use the commands on the Model Properties submenu to display or modify the model
properties associated with the model and its elements, or to display or modify model
property sets.
Edit
Opens the Options Dialog with the C++ Tab if nothing is selected. This tab is used to
display or modify model property values or model property sets.
Replace
Loads model property sets from the specified model property (.pty or .rtpty) file into
the current model. This command deletes all model property sets in the current
model, replacing them with the imported model property sets. A model component
attached to a model property set that is replaced becomes attached to the replacement
model property set. A model element attached to a model property set which is not
replaced becomes attached to its default model property set. To make the replaced
model properties a permanent part of the current model, you must save the model.
Export
Saves the current model's model property sets to a specified model property file (.pty
file). When you export model properties, all of the model property sets stored with the
model are written to a file that can be imported into another model.
This command displays a dialog in which you can specify the location and name of
the model property file to be exported.
Add
Adds new model properties from a model property set contained in a model property
file.
Menus 71
Update
Modifies the existing model properties in the current model by adding and/or
changing them to include the model properties in the update model property set. A
model element attached to a model property set that is updated becomes attached to
the updated model property set. A model element attached to a model property set
that is not updated becomes attached to its default model property set.
This command opens a File Browser so you can specify the location and name of the
model property file to be used to update the existing model properties.
To make the updated model properties a permanent part of the current model, you
must choose the Save command from the File menu.
Options...
Opens the Options Dialog, which provides control over many general model
properties. (See Toolset Options on page 550.)
Source Control
Opens a submenu of operations for interacting with a source control/configuration
management (CM) system. For information on Source Control options, see Source
Control Fundamentals in the Guide to Team Development for Rational Rose RealTime.
Configure...
Opens the Model Specification dialog on the Source Control tab, which allows you to
specify options relating to source control, to specify the source control system to use,
and to generate unique identifiers for all elements of the model.
Note: Generating unique identifiers affects the entire model. Review Unique Ids on
page 125 before setting this option.
Open Script
Opens a file browser to select a Rose REI or RRTEI script to open for editing. See The
Script Editor Window in the Rational Rose
RealTime Extensibility Interface Reference.
New script
Opens the script editor to create a new Rose REI or RRTEI script. For more
information, see The Script Editor Window in the Rational Rose
RealTime Extensibility Interface Reference.
From the script editor, you can invoke several dialogs.
Add Watch
Use the Add Watch dialog to add a variable to the Script Editor's watch variable list.
For more information, see Adding Watch Variables in the Rational Rose
RealTime Extensibility Interface Reference.
Modify Variable
Use the Modify Variable dialog to change the value of a selected watch variable. For
more, information, see Adding Watch Variables in the Rational Rose
RealTime Extensibility Interface Reference.
Menus 73
Find
Use the Find dialog to locate instances of specified text quickly anywhere within your
script. For more information, see Finding Specified Text in the Rational Rose
RealTime Extensibility Interface Reference.
Replace
Use the Replace dialog to automatically replace either all instances or selected
instances of specified text. For more information, see Replacing Specified Text in the
Rational Rose
RealTime Extensibility Interface Reference.
Calls
Use the Calls dialog to determine the procedure calls by which you arrived at a point
in your script when you are stepping through a subroutine. For more, information,
see Displaying the Calls dialog in the Rational Rose RealTime Extensibility Interface
Reference.
Go To Line...
Use the Go To Line dialog to jump directly to a specified line in your script. For more
information, see Moving the Insertion Point to a Specified Line in Your Script in the
Rational Rose RealTime Extensibility Interface Reference.
Dialog Editor
Use the Dialog Editor to insert or edit a dialog in your script. For more information,
see Working with the Dialog Editor in the Rational Rose
RealTime Extensibility Interface Reference.
TargetRTS Wizard
Simplifies the activities of building, configuring, managing and customizing the
TargetRTS libraries and build environment.
Connexis
Provides connectivity for Unified Modeling Language (UML) models.
Model Integrator
Opens the Model Integrator tool.
Web Publisher
Opens the Web Publisher tool.
C++ Analyzer
Opens the C++ Analyzer tool.
Add-Ins Menu
Add-In Manager
Opens the Add-In Manager dialog to activate or deactivate add-ins.
Several add-ins are shipped with the Rational Rose RealTime product, including:
■
C++ language code generators
■
Component Wizard
■
Add Dependencies
■
Generate Documentation
■ C language code generators
Menus 75
Other add-ins will be released through Rational RoseLink partners. See the Rational
Rose RealTime web site for links to RoseLink partner add-ins.
Window Menu
The Window menu has commands for manipulating the windows within the Rational
Rose RealTime environment, and a list of all the currently open windows. Use
commands from the Window menu to control the automatic placement of multiple
diagram and specification windows within the application window. You can also use
commands on the Window menu to redisplay windows that have been covered by
other windows or iconified.
To quickly bring a particular window to the forefront, select the name of the window
from the menu.
Cascade
Arranges all windows in an even-stepped arrangement. The windows are all sized to
a standard size, and the title bar of each window is visible while the body of each
window is covered by the next window in front. The most recently-viewed window is
completely visible.
Tile Horizontally
Arranges all windows horizontally within the Rational Rose RealTime window. The
application window is divided into equal-size areas, with one diagram or
specification window in each area. The most recently visited window is placed in the
upper left corner. Less recently-visited windows are placed to the right of more
recently-visited windows.
Tile Vertically
Arranges all windows horizontally within the Rational Rose RealTime window. The
application window is divided into equal-size areas, with one diagram or
specification window in each area. The most recently visited window is placed in the
upper left corner. Less recently-visited windows are placed below more
recently-visited windows.
Arrange Icons
Arranges collapsed windows evenly along the bottom of the Rational Rose RealTime
window.
Close All
Closes all currently open windows.
Window Selectors
The open windows within your application are listed on the Window menu with a set
of numerical selectors. The windows are listed by title. Selecting one of these items
from the menu opens the specified window and brings it to the forefront.
Help Menu
What’s This?
Opens the context-sensitive Help.
Contents
Opens the Help Table of Contents.
Search...
Opens the Help Search.
Index...
Opens the Help index.
Using Help
Opens a Help topic explaining how the Help system works.
Tutorials
Opens the Tutorials book from which you can choose tutorials based on your skill
level and background.
Example Models
Opens the Example Models book.
Menus 77
Keyboard Shortcuts
Opens a Help topic on keyboard shortcuts.
Browsers
Model elements are created and viewed through Browsers. The primary tab in the
browser is the Model View tab, which provides access to all elements of the current
model. Browsers list the model elements - usually in a hierarchical way - allowing
elements to be expanded to show additional information. Also, most browser lists can
be filtered in various ways.
The browser is an easy-to-use alternative to menus and toolbars for visualizing,
navigating, and manipulating items within your model.
The browser is a hierarchical navigational tool that lets you view the names and icons
representing use case, collaboration, deployment and class diagrams, as well as model
elements such as logical packages, classes, interfaces, associations and component
packages associated with the model.
Figure 14 shows the main application window with the Model View tab in the
browser.
Each of the views within the model displays as a separate folder in the Model View
tab in the browser. All model elements created within a view are displayed as
sub-elements of that view folder.
Browsers 79
Tabs
The tabs in the Browser are:
■
Model View Tab
■ Containment View Tab
■
Inheritance Tab
■
RTS Tab
Inheritance Tab
The Inheritance View tab shows the inheritance hierarchy of the capsule classes, data
classes, and protocols in the model.
RTS Tab
The RTS tab appears only when a component instance is run with Target
observability enabled. This tab provides a run-time view of the model, showing the
list of capsule incarnations, and providing buttons to control the model execution (see
Rational Rose RealTime Execution Interface on page 482).
Navigating
The plus sign (+) sign next to an icon indicates the item is collapsed, and additional
information is located under the entry. Click on the + sign and the tree is expanded.
Conversely, a minus (-) sign indicates the entry is fully expanded.
Double-clicking on the diagram name or icon displays the diagram. Double-clicking
on any other item displays the associated specification.
Docked:
■ The window can be moved within the dockable region of the frame, but it remains
positioned along the border.
■
The size remains fixed. The free side is resizable.
■
A ToolTip displays the icon title when partially covered by the browser border.
■
The window can be docked on any border.
Floating:
■ The window can be moved to any location, and is always displayed on top of the
diagram.
■
Size can be changed via click and drag along the border in a vertical or horizontal
direction.
Multiple Browsers
You can have multiple versions of the same browser, and apply filtering that is
different between them. For instance, you could open up a second browser and set its
filter to show only protocols and their signals.
Filtering
You can filter various packages, diagrams, and model elements using the Filter
dialog.
Browsers 81
Diagram Editors
There are several different kinds of diagrams that can be created and edited through
Rational Rose RealTime. Each diagram allows you to specify or document a different
aspect of the model. Some diagrams are accessible in only one view, while other
diagrams are found in more than one view. Each icon on a diagram represents an
element in the model. Since diagrams are used to illustrate multiple views of a model,
each model element can appear in none, one, or several of a model's diagrams. This
means you can control which components and properties appear on each diagram.
The following is the complete list of diagrams available in Rational Rose RealTime:
■ Activity Diagrams
■
Class diagram
■
Use case diagram
■
Collaboration diagram
■
Sequence diagram
■ Structure diagram
■
State diagram
■
Component diagram
■
Deployment diagram
■
Structure Monitor diagram
■
State Monitor diagram
See the individual diagram topics for information on creating or modifying that
particular diagram.
Each editor is displayed in a separate window. The diagram editors all have
associated toolboxes.
Diagram Editors 83
You can cut, copy, and paste icons between different diagram windows using
commands on the Edit Menu. The Edit menu also provides commands that enable
you to select, find, and rename icons. The Browse Menu provides commands to
navigate among diagrams, as well as create, rename, and delete them. Commands on
the Report Menu provide additional diagram navigation capabilities. You can print
diagrams using the Print command (see Print Specifications on page 119).
Opening Specifications
Clicking the Specification command from the Browse Menu displays the specification
for the model component represented by the selected icon.
Shortcut Menu
Clicking the right mouse button on an icon activates the popup menu, which enables
you to modify properties (for icons that represent relationships) or select properties to
be displayed within the icon. Select the Open Specification command from the context
menu to open the specification dialog.
Zoom
Zooms in on the current diagram. Select the zoom level.
Scale to Window
Enables the automatic resizing of icons to accommodate text.
Layout
Opens a submenu of options for rearranging the diagram:
Layout Diagram
Analyzes the location of all icons in the current diagram, determines the optimal
location for the icons, and redraws the diagram.
Align/Distribute
The selected objects are arranged according to the choices made in the dialog.
Alignment and distribution operations can be performed in both horizontal and
vertical arrangements.
Autosize All
Resizes all node views in the diagram to fit their labels.
Select in Browser
Selects an element from the diagram in the browser.
Filter
Use these options to filter information on diagrams.
Scroll Bars
Diagram windows provide vertical and horizontal scroll bars to pan across diagrams
larger than the window.
Diagram Editors 85
Overview Navigator and Toolset Buttons, and Class, Capsule, and
Protocol Specification Context Menus
Toolset Buttons
For descriptions of the buttons in the Toolbar, see The Toolbar on page 39.
Diagram Editors 87
Delete - Removes the selected element from the diagram.
Detach Target - Detaches observability, meaning that the toolset no longer
communicates with the running component instance. This menu item can only be
used with Attach Target.
Hide - Toggles the display of the Output window.
Load - Loads or downloads a component instance to a target platform. The load does
not start the execution of the loaded component instance. Use Run once it is loaded.
This is only used with target platforms that require loading of modules before they
are run. For platforms that do not require loading of modules, this menu item is
disabled.
Open Breakpoint Diagram - Displays the Breakpoint Diagram dialog from which
you can set breakpoints on a state machine.
Reload - Reloads a components instance. Used only with target platforms that require
loading of modules before they are run. For platforms that do not require loading of
modules, this menu item is disabled. This option unloads, then loads the component
without resetting the target board.
Rename - Changes the name of the currently selected element.
Restart - Kills the running component instance and runs another instance. If the
instance is running on an target board, the component is reloaded before a new
instance is run.
Run - Starts the execution of the component instance. If observability is configured to
attach at start-up the RTS browser appears. When observability is attached at start-up
the component instance is paused, or does not start processing messages, until you
click the Start button on the RTS Browser.
Save As - Saves the current output to a log file so that you can process the information
later.
Select All - Selects all the data in the current tab or window.
Shutdown - Kills the running component instance, closing the RTS Browser if
necessary.
Time Stamp - Prefixes messages posted to the log with a time stamp.
Scale to Window
Scales the current diagram down to fit entirely within the current diagram window
border. Scales according to the outer boundaries of the diagram - for example, the
outer state border of the state diagram - and not simply the area around visible
diagram elements.
Zoom
Zooms in on the current diagram.
Layout
Opens a submenu of options for rearranging the diagram:
■
Layout Diagram
Analyzes the location of all icons in the current diagram, determines the optimal
location for the icons, and redraws the diagram.
■
Align/Distribute
Opens the Align and Distribute dialog. The selected objects are arranged according
to the choices made in the dialog. Alignment and distribution operations can be
performed in both horizontal and vertical arrangements.
■
Change View Spread
Creates space in a diagram for adding new views or creates a cleaner appearance.
There are a number of different ways the views can be spread out by specifying the
Spread Technique.
Uniform - Indicates that the views are spread out across the diagram uniformly
by the percentage. If a view is at location (100,100) and they specified a
horizontal percentage of 10% and a vertical percentage of -10%, the new
location of the view would be (110, 90). This affects all views in the diagram the
same way.
Diagram Editors 89
Constant Radial - Indicates that the views spread outward/inward from a
central point. The preview displays a crosshair that specifies where the spread
starts. It can be moved around interactively in the preview window with the
mouse. The views spread out a constant distance based on the diagram size.
Decreasing Radial - Is similar to Constant Radial except that the views spread
progressively less far the farther away from the central point they are.
Increasing Radial - Is similar to the Constant Radial except that the views
spread progressively more the farther away from the central point they are.
The preview allows the user to play with the settings until the desired spread is
achieved.
■ Autosize All
Resizes all the objects in the diagram to fit their labels. The size of the objects
increase or decrease to the minimum size required for the label to appear.
■
Make Same Size
Makes two or more node views the same size in either height or width, or both.
You can choose from smallest, average, or largest of all the selected views to make
the new width and height. The dialog provides a preview screen.
■
Size Border from View
Adjusts the black border to fit within the size of the window.
Validate
Allows you to check the Sequence diagram specification for missing elements. It
provides control over what aspects of the Sequence diagram should be checked for
completeness.
Auto-Create FOC’s
Determines whether any new send or call messages automatically get an FOC (Focus
of Control) - and a return message, if appropriate - when they are created.
Difference
Initiates the differencing process for one or two selected sequence diagrams.
Toolboxes
Every diagram has an associated toolbox, which contains icons of tools that can be
applied to that diagram. If the current diagram is write-protected, the diagram
toolbox is not displayed. The diagram toolbox is also only available when a diagram
is displayed.
There are several tools that are common to every toolbox:
Selector Tool
Selects objects for moving, resizing, and so forth.
Zoom Tool
Zooms in on a portion of the diagram. Click on the tool and then click on the part of
the diagram you want to zoom in on.
Text Tool
Adds text anywhere in the structure diagram.
Diagram Editors 91
Note Tool
Annotates the diagram with textual notes. This is useful for marking up the diagram,
for example, with explanations and review comments. You can also drag and drop a
diagram or external document from the browser onto a note. When the name of the
diagram or external document is underlined, the name is a hyperlink to a diagram or
URL. If you double-click on the note, the diagram or external document opens.
Constraint Tool
Adds UML constraints to any diagram. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
Specification Dialogs
Specification dialogs are used to edit the properties of any element in the model. All
specification dialogs contain at least a Name and Documentation field. Some
specification dialogs contain many fields split across different tabs. The example
below shows a specification dialog with multiple tabs. All properties of a modeling
element are accessible through the specification dialog for that element. Many of the
properties on the specification dialog are also visible/editable through one or more
diagram editors.
Specification dialogs are resizable. The tab you are in is remembered so that the next
time you open the specification dialog you go to the same tab. The position and size of
specification dialogs are saved with the workspace.
Specification Dialogs 93
Browse
Clicking Browse displays the following context menu options:
■
Select in Browser - Highlights the selected element in the browser.
■
Open Diagram - Opens the diagram associated with the object.
■ Browse Parent - Opens the Specification dialog for the parent of the selected
element.
■
Browse Selection - Opens the Specification dialog for the currently selected
element.
■ Browse Superclass - Opens the Specification dialog for the superclass of the
selected object.
■ Browse Subclasses - Opens the Specification dialog for the subclasses of the
selected object.
■
Show Usage - Displays a list of all diagrams in which the currently selected
element is the supplier, or in the case of a collaboration diagram, a list which
shows the usage of a message.
■
Find References - Finds a specified item in the model by searching all fields -
excluding Documentation - and searching all objects - excluding Diagrams,
Component Instances, devices, Instances, Interactions, Messages, Packages,
Probes, and Processors. This command displays the Find In Model Dialog so that
you can type the search string.
OK
Accepts changes and closes the dialog.
Cancel
Ignores changes that were made and closes the dialog.
Apply
Commits any changes that were made.
Help (?)
Opens the Online Help for the current Specification dialog.
Exit (X)
Closes the specification dialog.
Tabs
Many dialogs include a number of tabs across the top for grouping different
specification information. The Files Tab, Relations tab, Components tab, Attributes
tab, Operations tab, and Unit Information Tab may be displayed for many different
model elements. Unit Information tab only appears if the model is being controlled as
units.
Actions Tab
Type
Displays the action specified in the Action Specification dialog:
■
Action - A simple action may be the invocation of a method, or the starting or
stopping of an activity.
■
Send Event - Send events are actions that trigger another event.
The type of action determines what options are available in the dialog box.
Double-click on an action to open the Action Specification dialog for the selected
action. If there are no actions listed, right-click on the Actions tab and click Insert.
Action Expression
Displays the timing option that specifies when to carry out an action and the types of
actions that are carried out. Actions on activities can occur:
■
on entry - The task is performed when the object enters the activity
■
on exit - The task is performed when the object exits the activity
■
do - Dhe task is performed while in the activity and must continue until exiting the
activity
■
on event - The task triggers an event only when a specific event is received
You can modify the action settings through the Detail tab of the Action Specification
dialog.
Specification Dialogs 95
Attributes Tab
The UML asserts that attributes are data values (string or integer) held by objects in a
class. Thus, the Attributes tab lists attributes defined for the class. The attribute
definition can be modified through the Attribute Specification dialog.
Note: Attributes and relationships created using this technique are added to the
model, but do not automatically appear in any diagrams. That is, adding an attribute
affects the code generation for the class and a compilation dependency between the
class of the container and the class of the attribute, but these relationships are not
graphically visible in the model.
The descriptions for each field follow:
■ Visibility Adornment (Unlabeled):
❑ Public - The attribute is publicly visible, and is accessible to all clients.
❑ Protected - The attribute may be accessed only by subclasses, friends, or by
operations of this class.
❑
Private - The attribute is accessible only by the class itself or by its friends.
❑
Implementation - The attribute is accessible only by other operations in this
class.
■
Stereotype - Displays the name of the stereotype.
■
Name - Displays the name of the attribute.
■
Class - Identifies where the attribute is defined.
■ Type - This can be a class or a traditional type, such as int.
■
Initial - Displays the initial value of an object.
The Attribute tab is active for all class types.
Show Inherited
Click this option to see attributes inherited from other classes. If there is no check
mark in this field, you can view only attributes associated with the selected class.
Note: Rational Rose RealTime allows you to directly modify any attribute shown in
the attributes list by displaying the attribute specification dialog. You should be
careful when modifying base class attributes for it may have implications on other
elements in your model which reference or are subclassed from the base class.
Components Tab
The components list displays a list of components to which this class has been
assigned. Components can be inserted, deleted, and moved up and down in the list.
Each component has a corresponding Component Specification for editing the
component attributes.
A check-box provides filtering control over which components are displayed:
Show all components displays the list of all components in the model.
Right-clicking on a component brings up the Components popup menu.
Detail Tab
When
Specifies a timing option to carry out for the selected action.
On Event
The On Event parameters are only enabled when you set the On Event timing
parameter in the When box.
■ Event - In an Activity Diagram, an event is an occurrence that can trigger a state
transition. Type the name of the event that will trigger the action.
■
Arguments - Specifies any optional arguments associated with the event.
■
Condition - Specifies a conditional Boolean expression.
You can use an On Event action rather than a self-transition because self-transitions
trigger all the actions associated with a state, whereas state and activity actions handle
internal state and activity transitions. This means that you can process an internal
event without triggering the entry and exit actions.
Specification Dialogs 97
Type
Specifies the type for the action.
■
Action - A simple action may be the invocation of a method, or the starting or
stopping of an activity.
■ Send Event - Send events are actions that trigger another event.
The type of action determines what options are available in the dialog box.
Name
Specifies a name of the Action or Send Event. This name appears on the state or
activity on the Activity Diagram.
Send arguments
Specifies any arguments for a send event. One or more arguments can accompany a
send event.
Send target
Specifies any targets for the send event. A target is any object that will receive the
transition event.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
General Tab
Name
Specifies the name for the currently selected state.
Stereotype
Specifies a keyword that further defines the classification of the model element. A
stereotype represents the subclassification of a model element. Some stereotypes are
already predefined, but you can also define your own to specify new modeling types.
Owner
Specifies the model elements that own the selected state.
Context
Specifies a view for a related set of modeling types.
Documentation
Describes model elements or relationships. The description can include such
information as the constraints, purpose, and essential behavior of the element. The
information you type in this field is not displayed in the Activity Diagram.
State/activity history
Specifies whether to return the most recently visited state or activity when
transitioning directly to a state or activity with sub-states or sub-activities. Set this
option to apply history at the state or activity level.
History provides a mechanism to return to the most recently visited state when
transitioning directly to a state with sub-states. History applies to the level in which it
appears. It may also be applied to the lowest depth of nested states.
Operations Tab
Operations denote services provided by the class. Operations are methods for
accessing and modifying Class fields or methods that implement characteristic
behaviors of a class.
Specification Dialogs 99
The Operations tab lists the operations that are members of this class. The actual
definition of the operation is accessible from the Operation Specification.
The operations are listed with the following fields:
■
Visibility Adornment (Unlabeled) - The visibility of the operation is indicated
with an icon. Following are the visibility options:
❑ Public - The operation is accessible to all clients.
❑ Protected - The operation is accessible only to subclasses, friends, or to the class
itself.
❑
Private - The operation is accessible only to the class itself or to its friends.
❑
Implementation - The operation is accessible only by operations of this class.
■
Stereotype - Displays the name of the stereotype.
■
Signature - Displays the name of the operation.
■
Class - Identifies which class defines the operation.
■
Return Type - Identifies the type of value returned from the operation.
The Operation tab is active for all class types. In the class diagram, you can display
operation names in the class compartment.
Show Inherited
Click this option to see operations inherited from other classes. If there is no check
mark in this field, you can view only operations associated with the selected class.
Note: Rational Rose RealTime allows you to directly modify any operation shown in
the operations list by displaying the operations specification dialog. You should be
careful when modifying base class operations for it may have implications on other
elements in your model which reference or are subclassed from the base class.
Relations Tab
The relations list displays relations between classes as specified in diagrams. Relations
can be inserted, deleted, and moved up and down in the list. Each relation has a
corresponding Association specification for editing the relation attributes.
A check-box provides filtering control over which relations are displayed:
Show Inherited shows any relations inherited from a superclass.
Swimlanes Tab
Name
Specifies the swimlane name where the enclosed state or activity resides.
Transitions Tab
Event
Specifies the names of all the events for transitions associated with the selected
element.
An event causes a state transition. You do not have to uniquely label events because
one event can cause a transition to many different states or activities.
End
Specifies the target state or activity for transitions.
Descriptions
Owned by model
Indicates whether the unit is owned by this model or whether it is owned by another
model and shared into this model. This setting is not directly editable.
Scratchpad
Indicates that the package is a scratch pad. This check box is only enabled in the Unit
Information tab for a package that is not under source control.
Filename
Displays the name of the file that is used to save this controllable unit. This field is not
directly editable.
Save As
For controlled units, this option saves the selected unit, and if specified, its child units
(if any exist), to a new location.
If the model is under source control, Rational Rose RealTime prompts you to check
out the parent unit before proceeding with the Save As operation.
If you cancel the Save As operation, the unit file names change back to the names
previous to clicking the Save As option; however, any files already saved are not
deleted from your hard drive.
You cannot undo the Save As operation.
Note: The containing unit of the unit you click Saved As for is identified as being
modified. It is essential to save the model to update the containing unit. If the parent
unit is not saved, it will point to the original file location.
Using Sort
If you select Output to Find 2 pane in the Find In Model dialog, the results display in
the the Find 2 tab of the Output window.
The results of searching displays a list of diagrams in which that item appears. You
can double-click on an entry in the Find tab or click Browse to go directly to the
Specification dialog or diagram.
The wildcard is particularly useful for finding any classes or packages that were
automatically renamed in a model that was upgraded from a previous release. For
example, you can search for every model item that was renamed by typing the
following:
*#*
Every model item that has a pound symbol (#) in its name will be found.
Searching Code
The Find in Model dialog searches for specified text in all detail level code in a model:
transitions, entry and exit code, choice points, guards, and operations. It also searches
the dimension and type property of all attributes, the data type of signals,
documentation, and language tab properties.
Replace Dialog
You can use the Replace dialog to search and replace detail code segments or to search
and replace for model elements by name. Results are displayed in the Find 2 tab of the
Output window (View > Output).
Searching Code
Use the Replace dialog to find and replace all uses of a class in detail code or which is
a property of another class. For example, you could find and replace attributes of a
specific type or signal data types of a specific name.
Selective searching
You can toggle several items at once by pressing the SHIFT key, then selecting a set of
elements types from the list, then using the SPACEBAR to change the selection of the
options.
Description Window
The Description window contains the Documentation Tab and the Code Tab. You can
toggle between the two by clicking their tabs.
109
Characteristics unique to the window state (docked or floating) are:
■ Docked on page 110
■
Floating on page 110
Docked
■ The window can be moved within the dockable region of the application.
■
The size can be changed using the splitter bars.
■
The title can be displayed through a tool tip (simply place your cursor anywhere in
the window). There is no title available when the window is docked.
■ The window can be docked at any time.
Floating
■ The window can be moved to any location, and is always displayed on top of the
diagram.
■
Size can be changed using click and drag along the border in a vertical or
horizontal direction.
The window title displays the description. The static text displays the name of the
element who’s code or documentation you are viewing.
Documentation Tab
You can use the Documentation tab to edit or view the documentation associated
with the currently selected model element. Scroll bars are added when necessary and
word wrap is employed.
Code Tab
You can use the Code tab to edit or view the code associated with the currently
selected model element. Scroll bars appear when necessary and word wrap is
employed.
Word Wrap
To enable or disable word wrap in a text box, such as a Documentation box or Code
box, right-click in Code box and select Word Wrap. The keyboard shortcut to toggle
Word Wrap is CTRL + O.
Note: Word wrapping only affects the display of text. When saving or exporting,
Word Wrap is set, it does not affect the output format for the text. The Word Wrap
menu option is only enabled when the edit window contains text.
Popup Menu
Using the popup menu, you can
■
import and export files containing code
■ print the code
■ select individual words, lines, or all of the code you are viewing
■
specify the font
■ use the Search feature to Find and Replace
■
launch an external editor
Note: If you use an external editor that requires a console terminal, you must specify
an application, such as xterm, that provides the terminal, followed by the editor
command itself.
Note: Example on Solaris: /usr/openwin/bin/xterm -e /bin/vi
To add code to a model element, you can use the code window or
1 Right-click on the model element in the model browser or in a diagram.
2 Select Open Specification from the selected item's menu.
3 Click on the language-specific tab if it is not the tab currently displayed.
4 Enter the code.
5 Close the Specification dialog by clicking OK.
Output Window
The Output window (see Figure 19) is a dockable window that contains the following
tabs:
■ Log Tab
■
Build Log Tab
■
Build Errors Tab
■
Find Tab
■
Watch Tab (RTS only)
Log Tab
The Log tab is used by several commands to report progress, results, and errors.
Messages posted to the log are usually prefixed with a time stamp.
To display the Log tab, select View > Output. The application posts the messages to
the log window regardless of whether it is displayed.
The Build Log tab contains the raw output stream from the build. You can examine
the contents of this window to get a context on any error message displayed in the
build messages list.
Watch Tab
Capsule instance attributes can be inspected at run-time and modified from the
Watch tab of the Output window. The Watch tab has two columns: the name of the
attribute and its value.
To add an attribute instance, or variable, to the watch window, open a state monitor
and drag-and-drop the attribute from the Attributes folder into the watch window.
You can also edit the value of a variable by selecting the Value field then entering
another value for the variable.
ToolTips
The ToolTips for the elements whose Specification dialogs appear in the list display
the fully qualified name for the element and, if it has any context, the short name of
the context displays on the second line of the ToolTip.
Keyboard Shortcuts
For a printable list of shortcut keys, see Keyboard Shortcuts on page 565.
By default, the current Specification dialog will close before the previous or next
Specification dialog will display. If you open a Specification dialog using the toolset
(and not using the previous and next shortcut key commands, that specification
appears on the top of the Specification History list. If that Specification dialog already
exists in the Specification History list, the earlier entry is removed from the list.
Note: The shortcut keys for the Specification History window,
[Shift+]Alt+{PgDn|PgUp}, are not available in the Add-ins.
The previous and next shortcut key commands "wrap" around the list. If specification
corresponding to the current item is not open, it will be opened first.
Most of the operations on the elements of Specification dialogs in the list will be
performed using the shortcut menu. Operations are performed on the selected
elements only, and multi-selection is permitted.
Print Specifications
The Print Specifications dialog lets you print diagrams. As well, you can adjust the
parameters of diagrams you want to print, including size, orientation, and layout.
The dialog has four tabs:
■
General Tab
■
Diagrams Tab
■
Specifications Tab
■
Layout Tab
All tabs contain the Print Preview button, which you can click to see how your
diagram will appear before you route it to a printer.
General Tab
The General tab contains three fields:
■ Printer Area
■
Print Range Area
■
Copies Area
Printer Area
In the Printer area, you can select the name of the printer you want to use from a
drop-down menu. Select the Print to File option to print a diagram to a file, instead of
routing it directly to a printer. You are prompted to specify a filename and location.
As well, there is a Properties button.
119
Properties Dialog
Clicking Properties opens the Properties dialog, which contains two tabs: Layout and
Paper/Quality.
Click the Advanced tab to fine-tune your printing parameters.
Copies Area
The Copies area lets you specify the number of copies you want to print, and whether
you want multiple copies collated.
Diagrams Tab
The Diagrams tab contains the options that you can choose from to generate a
printout of one or more diagrams.
Note: If all the options on the Diagrams tab are grayed out, click the General tab, then
in the Print range box, select Selected diagrams and click Diagram Options.
The Diagrams tab has the following areas: Use case diagrams, Class diagrams,
Component diagrams, Deployment diagrams, and Interaction diagrams.
The first four fields contain the following buttons:
■
Top Level - Prints only the diagrams at the top level of the model.
■
Entire Structure - Prints all the diagrams.
■
None - Prints none of the diagrams.
The Include State Diagrams check box is not applicable unless you have chosen Top
Level or Entire Structure in the Use Case or Class Diagrams fields.
The Interaction Diagrams List Control lets you select each object message or message
trace diagram containing objects whose specifications you want to print. The All
button selects all object and interaction diagrams in the list. The None button
deselects all object and interaction diagrams in the list.
Layout Tab
The Layout tab contains the options that you can choose from to change the position
and size of the diagrams you want to print. If your print job is larger than the
available paper, you can tile your work so that it is spread across several pieces of
paper. Assemble the separate pages to create the whole image.
The Layout tab contains two areas: Positioning and Options.
Positioning area
The Positioning field contains the options that you can choose from to change the size
of the diagrams you want to print.
■
As In Diagram -Pprints diagram as you see it on screen.
■
Fit To Page - Resizes each diagram to a single page.
■ Tile -Eenables the Options field.
Print Setup
The Print Setup dialog lets you set up print options, generally. The dialog contains
three areas: Printer, Paper, and Orientation. As well, there is a Network button.
Clicking this button opens the Connect to Printer dialog, which lists shared printers
on the network. Click on a particular printer to route your print jobs to it.
Printer Area
The Printer area lets you select the name of the printer you want to use from a
drop-down menu. You can also click Properties to open the Properties dialog.
Paper Area
The Paper area lets you specify the size and source of the paper you want to use to
print.
Orientation Area
The Orientation area lets you choose between Portrait and Landscape orientations.
Unique Ids
Unique ids are unique internal names associated with model elements. They are used
internally by Rational Rose RealTime, and not all model elements require unique ids.
Rational Rose RealTime includes a feature that helps Model Integrator by generating
unique ids for those model elements that would otherwise not require them, for
internal use. For Model Integrator, an element with a unique id is easier to merge.
RRTEI users will find traceability easier when they set this option. Unique ids
improve the traceability of model elements of other tool integrations that use RRTEI.
It is necessary to plan and choose when to incorporate the new unique ids into the
project model since virtually all controlled units will be modified implicitly.
Additionally, the generated new ids are dependent on time and location. For example,
generating unique ids for a given model at different times, or on different machines,
produces different ids.
The following model elements do not have unique ids, unless you set this option:
■ Protocol In Signals ()
■
Protocol Out Signals ()
■
States (CompositeState)
■ Capsule Roles (CapsuleRole)
■
Ports (Port)
■ Port Roles (PortRole)
■ Capsule Structure diagram (CapsuleStructure)
■
Classifier Role (ClassifierRole)
125
■
Transitions (Transition)
■ Junction Point (JunctionPoint)
■
Choice Point (ChoicePoint)
■
Connectors (Connector)
■ (Guards)
■
(Events)
■
(EventGuards)
■ Parameters ()
■
Element hyperlinks (ExternalDocument)
Caution: We strongly recommend any team involved in parallel development use this
option.
Note: Setting this option creates unique ids for model elements that currently do not
have them. This typically affects most of the model, so you will be prompted to check
out those parts when setting this option.
When saving the model, the size of the affected file increases by approximately 20%,
and the time to load the model also increases.
Caution: Do not set this option for multiple streams as shown in Figure 21; otherwise,
objects with similar characteristics will be treated differently since their unique id’s
will differ.
For information on how to enable the Unique ids, see Model Specification on page 129.
To clear the unique id option, follow the same procedure in Figure 22.
Note: If you clear this option, your merge results will not be as reliable.
Model Specification
A Model Specification enables you to display and modify the properties of the top
level element.
To display a Model Specification, right-click on the top level element and choose
Open Specification.
Specification Content
The Model Specification contains the following tabs:
■
General Tab
■
Source Control Tab
■
Files Tab
■
Unit Information Tab
General Tab
Name
Identifies the name of the model.
Files Tab
Provides a list of referenced files. The files list pop-up menu allows you to insert and
delete references to files or URLs.
Note: You can link external files to models for documentation purposes.
Owned by model
For units, it indicates that the selected unit is owned by the model.
For models, it indicates that this mode is owned by another model.
For collaborations, it indicates whether the unit is owned by this collaboration, or
whether it is owned by another model and shared into this model. When selected, it
indicates that this collaboration is owned by another model.
Scratchpad
Indicates that the package is a scratch pad. This option is only enabled in the Unit
Information tab for a package that is not under source control.
Version
Displays the version identifier for this controlled unit. If this information is not
known, then "<unknown>" displays. The ability to extract this version information
depends on the source control tool being used. If a unit is not under source control,
then this field is not displayed.
File Name
Displays the file name of the model, or the name of the file used to save this
controllable unit. This field is not directly editable..
A Workspace
A workspace contains basic configuration information for working with a model. This
information includes the name of open model, whether source control is enabled, and
any settings related to how source control and file management behave when editing
the model.
The workspace information is stored in a separate file (.rtwks). When a model opens
and a workspace file of the same name exists in the directory, the toolset prompts you
to open the workspace instead. If you regularly work on a particular model, open the
workspace corresponding to that model rather than just opening the model itself.
Importing requirements
Requirements captured in ObjecTime Developer Models can be converted through a
requirements-specific patch for 5.2 and 5.2.1. An HTML file is generated that contains
the actual requirements from the OTD models. Links to these requirements are
converted when the actual model is imported into Rose RT. The HTML requirements
file is stored outside of the Rose RealTime toolset. Place the file in your configuration
management library for storage purposes.
See the ObjecTime Developer Conversion Guide for information on converting from
ObjecTime Developer.
Before Starting
Rational Rose RealTime can open files (.mdl files) saved with Rational Rose 4 and on.
Fixing a Model
When importing a model from Rose into Rose RealTime, you are encouraged to
resolve any model errors in Rose (Tools > Check Model) before trying to import the
model. In particular it is important to fix unresolved references. In general, Rose is not
concerned as much about unresolved references; however, they are very important in
Rational Rose RealTime as they can result in incomplete code generation and
compilation errors.
Example
Imported a Rational Rose model, made some changes to the Component View, now
the file will not reload in Rational Rose RealTime.
137
Using the Use Case Diagram Editor
Use case diagrams present a high-level view of how a system is used as seen from an
outsider’s (or actor’s) perspective. These diagrams depict system behavior (also
known as use cases). A use case diagram may depict all or some of the use cases of a
system.
A use case diagram can contain:
■ actors ("things" outside the system)
■ use cases (system boundaries identifying what the system should do)
■
interactions or relationships between actors and use cases in the system including
associations and generalizations
Use case diagrams can be used during analysis to capture the system requirements
and understand how the system should work.
The use case diagram editor is used to create a diagram showing use cases and the
relationships among use cases, actors and classes. The use case diagram consists of
two parts: the diagram area and the Use Case Diagram Toolbox.
The Title bar shows the full name of the Class diagram.
141
Specification Content
The Use Case Specification contains the following tabs:
■
General Tab
■
Diagram Tab
■ Relations Tab
■
Files Tab
General Tab
In addition to the elements found in standard Specification Dialogs, the General tab
contains:
Name
A use case name is often written as an informal text description of the external actors
and the sequences of events between elements that make up the transaction. Use-case
names often start with a verb. The name can be entered or changed on the
specification or directly on the diagram.
Package
This static field identifies the package to which the components belong.
Stereotype
A stereotype label. A stereotype represents the subclassification of an element. For
example, an actor is a stereotype of a class. Some stereotypes are already predefined,
but you can also define your own.
Rank
The Rank field prioritizes use cases. For example, you can use the rank field to plan
what iteration in the development cycle a use case should be implemented.
Abstract
An abstract notation indicates a use case that exists to capture common functionality
between use cases (uses) and to describe extensions to a use case (extends).
Documentation
Provides a description for this Use Case.
Diagrams
The Diagrams box lists all the diagrams owned by the use case. The diagram list
consists of two columns. The first (unlabeled) column displays the diagram icon type
for the diagram. The second column displays the diagram name. To insert a new
diagram in the list, right-click and select one of the Insert options from the shortcut
menu that corresponds to the diagram type.
Relations Tab
Relations
The Relations box lists all the relationships associated with the selected use case. The
client and supplier names and type icons display to the right of the relation name.
Double-clicking on any column in a row displays the element's specification.
Files Tab
Contains a list of referenced files. The files list shortcut menu allows you to insert and
delete references to files or URLs.
Note: You can link external files to model elements for documentation purposes.
Creating an Actor
You can create Actors in the Use Case View of the Model View tab in the browser.
Actor Specification
An Actor Specification looks identical to a Class Specification, except that the
stereotype field is set to actor. However, some of the fields in the class specification are
not applicable to actors and are therefore disabled.
145
To edit the Main class diagram:
1 Double-click on the Main diagram in the Logical View package in the Model View
tab in the browser. The Class Diagram editor appears.
2 Place classes, packages, capsules, and protocols in the diagram by dragging them
from the model browser, or by using the tools in the toolbox.
3 Draw relationships and associations among the classes, packages, capsules, and
protocols using the toolbox.
Relationships
There are four basic kinds of relationship you can create through the class diagram.
Refer to the following topics:
■
Creating Association Relationships on page 154
■ Creating Aggregation Relationships on page 160
■
Creating Dependency Relationships on page 167
■
Creating Inheritance Relationships on page 162
Zoom Tool
Use to zoom in on a portion of the class diagram. Click on the tool and then click on
the part of the diagram you want to zoom in on.
Text Tool
Use to add text to the class diagram.
Note Tool
Use to annotate the diagram with textual notes. This is useful for marking up the
diagram with explanations, review comments, and so forth. You can drag and drop a
diagram or external document from the browser onto a note. Notice that the name of
the diagram or external document is underlined. If you double-click on the note, the
diagram or external document is opened. You can undo and redo this command.
Constraint Tool
Use to add UML constraints to the class. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
Class Tool
Use to place a class on the class diagram. (See Using the Class Diagram Editor on
page 146.) Pops up a pick list allowing you to choose from an existing class or create a
new class.
Capsule Tool
Use to place a capsule class on the class diagram. (See Using the Class Diagram Editor
on page 146.) Pops up a pick list allowing you to choose from an existing capsule class
or create a new capsule class.
Association Tool
Use to draw an association between two classes on the class diagram. (See Using the
Class Diagram Editor on page 146.) Associations can be created between classes
(including class utility, parameterized class, and so on), between capsule classes, and
from capsule classes to protocol classes.
Aggregation Tool
Use to draw an aggregation between two classes on the class diagram. (See Using the
Class Diagram Editor on page 146.) Associations can be created between classes
(including class utility, parameterized class, and so on), between capsule classes, and
from capsule classes to protocol classes. See Creating Aggregation Relationships on
page 160 for more information.
Unidirectional Association
Use to draw a unidirectional association between two classes on the class diagram. A
unidirectional association is simply an association with navigability limited to one
direction. Associations can be created between classes (including class utility,
parameterized class, and so on), between capsule classes, and from capsule classes to
protocol classes. See Creating Relationships on page 153 for more information.
Association Class
Use to link a class with an association between two other classes on a class diagram.
Use the Association Specification (by double-clicking on the association after it has
been drawn) to specify details of the association semantics. Using the link attribute
tool automatically sets the Link Element field on the association to be the class joined
to the association with the link attribute tool.
Generalization
Use to indicate that one element is a generalization of another. This is primarily used
to indicate a superclass/subclass relationship between classes. Draw the relationship
from the specializing element to the generalizing element (that is, from subclass to
superclass). Use the Generalize Specification (by double-clicking on the generalization
after it has been drawn) to specify details of the generalization semantics.
Adding a generalizes relationship between two classes (including capsule and
protocol classes) results in one class being generated as a subclass of the other at code
generation time.
Dependency or Instantiates
Use to indicate that one element is dependent on another. This is primarily used to
indicate a compilation dependency between classes. Draw the relationship from the
dependent element to the dependent-upon element. Use the Dependency
Specification (by double-clicking on the dependency after it has been drawn) to
specify details of the dependency semantics.
Adding a dependency relationship between two classes (including capsule and
protocol classes) results in the dependent class including the .h file of the
dependent-upon class.
Package
Use to add a package to the diagram. The package is given a default name such as
'NewPackage1'.
Use Case
Use to place a use case on a diagram. This creates a new use case with a default name
such as 'UseCase1'.
Interface
Use to place an interface on a diagram. Displays a pick list allowing you to select a
class or create a new class.
Realize
Use to indicate that a class realizes an interface or a use case. Draw the relationship
from the realizing element to the element being realized.
Instantiated Class
Use to place an Instantiated class on the class diagram. Displays a pick list allowing
you to choose from an existing class or create a new class. There is no code
generation support for instantiated classes.
Creating Relationships
Relationships among modeling elements take many forms. Most relationships imply
an interaction or a dependency between two model elements. The term 'class' in the
following descriptions includes capsule and protocol classes as well as "data" classes.
Association Specification
An association represents a semantic relationship between two classes. To display the
association specification, double-click any association in a class diagram.
Specification Content
The Association Specification dialog consists of the following tabs: General Tab,
Detail Tab, End A Detail, End B Detail, End A General, End B General, and
language-specific tabs.
General Tab
Name
A name for the association. The name label appears on the class diagram.
Effect on generated code: None.
Parent
The parent the component belongs to (its package) is displayed in this non-editable
field.
End A / B
Labels the ends with names that denote the purpose or capacity wherein one class
associates with another. This field is the same as the End field on the End A General
and Detail and End B General and Detail tabs. See the End Detail tab for more
information.
Element A/B
Specifies the classes of the two elements that this association associates. This field
cannot be edited.
Note: Click the Element A or Element B hot link to open the Specification dialog for
that object.
Detail Tab
Derived
Indicates whether the association is computed or implemented directly. The element
name for a derived element is adorned by a “/” in front of the name.
Effect on generated code: No code is generated for derived associations.
Association Class
Lists the attributed associations linked to the association. These attributed
associations apply to the association as a whole. It identifies a class representing the
association between the two elements.
Effect on generated code: Each of the end classes has a member generated to point to
or contain an instance of the link class, depending on the settings of the containment
property. The link class has members generated to point to or contain each of the ends
of the association.
Note: If the Association class box contains a class, the corresponding label becomes a
hot link to the Specification dialog for that class.
Constraints
The constraint is an expression of some semantic condition that must be preserved
while the system is in a steady state. The constraint on the Detail tab applies to the
association as a whole, while the constraint on the Detail A or Detail B tab applies to a
particular end.
To apply a constraint, click in the Constraint field and enter the text. Constraints are
displayed notationally, surrounded by braces under the end for which it applies.
Effect on generated code: None.
End A / B
Labels the end with a name that denotes the purpose or capacity wherein one class
associates with another. This field is the same as the End A and End B fields on the
General tab.
Effect on generated code: The end name is generated as a member of the class at the
other end of the association. That is, if the class at End A is class A and the class at End
B is class B, and the name of End A is foo, then class B will have a member named foo
of type Class A.
Element
Describes the two elements that this association associates. This field cannot be edited.
Note: Click the Element hot link to open the Specification dialog for that element.
End
A label for the end. This label appears beside the end on the association in the
diagram. This field is the same as the End field on the General and End A and End B
General tabs. See the field description on the End A/B General tab for more
information.
Element
A non-editable field that specifies the classifier for this end.
Note: Click the Element hot link to open the Specification dialog for that element.
Constraints
The constraint is an expression of some semantic condition that must be preserved
while the system is in a steady state. The constraint on the Detail tab applies to the
association as a whole, while the constraint on the Detail A or Detail B tab applies to a
particular end.
Effect on generated code: None.
Multiplicity
The multiplicity field defines the maximum number of instances that can exist in this
end of the association at any given time. See Multiplicity options for more
information.
Aggregation
The Aggregation field has three checkboxes: None, Aggregate, and Composite.
■
None - The end is not an aggregate.
■ Aggregate - The end is an aggregate; therefore, the other end is a part and must
have the aggregation value of none. The part may be contained in other
aggregates.
■ Composite - The end is a composite; therefore, the other end is a part and must
have an aggregation value on none. The part is strongly owned by the composite
and cannot be part of any other composite.
Use the Aggregation field to set a direction to either all or part of the relationship
among instances of these classes. Only one end of the relationship can be aggregate or
composite.
To set the aggregate adornment, click on the Aggregate box in the Association
Specification or click Aggregate through the shortcut menu. The adornment is a
diamond on the relationship.
Effect on code generation: This affects how the other end is stored as a member of this
class. Checking the aggregate box allows you to select a containment setting to control
how the aggregation will actually be generated in code.
Target Scope
The Target Scope field has two checkboxes: Instance and Classifier.
■
Instance - Specifies that instances of the client own the supplier class.
■
Classifier - Specifies that the client class - not the client’s instances - owns the
supplier class.
You can set this field in the specification or through the shortcut menu.
Effect on code generation: The data member is scoped to the classifier in the other end
class.
Navigable
The Navigable field indicates in which direction the association is traversed. By
default, ends are bidirectional and no navigation notation is provided.
To set an end's navigation, click on the Navigable box in the Association Specification
or click Navigable through the shortcut menu. The navigable arrowhead points in the
direction of the end, unless a containment adornment is displayed. Containment
adornments override navigable adornments.
Effect on code generation: If the navigation check box is not checked, it signifies
that the class at the other has no visibility of the class at this end of the association;
therefore, no member will be generated in the other end class.
Keys/Qualifiers
A key or qualifier is an attribute that uniquely identifies a single target object. The
attributes allow 1..n or n..n associations, and reduce the number of instances. The list
box displays all keys or qualifiers currently defined.
To enter a key or qualifier, click Insert from the popup menu or press the insert key.
An untitled entry is placed in the name and type field. To change the entry, select to
highlight and type in a new name.
Effect on generated code: The Keys/Qualifiers entries currently have no effect on
generated code.
for sending/receiving data.
Considerations
■
An instance of the contained class cannot exist outside of an instance of the
aggregate class.
■
The creation of an instance of the aggregate class usually results in the automatic
creation of an instance of the contained class.
■
The destruction of an aggregate instance results in the automatic destruction of
any contained instances.
Implementation details of the aggregation, such as whether the contained object is
referenced by a pointer or embedded, can be specified through the End A and B
General Tabs and End A and B Detail Tabs.
Figure 26 shows the aggregation representation in the aggregation compartment on
the class diagram.
This compartment only exists for classes and capsules. An aggregation displays in the
aggregation compartment only if the aggregation causes the generation of a member
variable for the class. This means that if the appropriate end is navigable, the
aggregation appears in the compartments for that class or capsule.
Aggregation Specification
An aggregation represents a special bidirectional semantic relationship between two
classes, wherein one or more instances of one class are contained within an instance of
the aggregating class.
The aggregation specification dialog is the same as the Association Specification with
the End A aggregate check-box turned on.
Exclusions
When you create a new generalization between capsules or protocols, the Inheritance
Rearrangement dialog may appear prompting you to exclude new superclass
properties. This allows the subclass to not inherit certain properties (state machine,
capsule structure and protocol signals) defined in the superclass. This is helpful, for
example, if your subclass has a state machine and you want to intelligently merge the
state machines rather than just blindly inherit the superclass state machine. You can
initially exclude the superclass elements, and then gradually re-inherit them as you
edit your state machine.
If you select Copy or Cut from the Edit menu, a dialog appears warning you that
items whose parents are not being cut or copied will not get pasted. You have the
option of checking the box, do not warn anymore this session.
See Inheritance for more information.
Generalize Specification
A generalize relationship between classes shows that one class shares the structure or
behavior defined in one or more other classes.
The Generalize Specification consists of the following tabs: General and Files.
Name
A name for the relationship.
Owner
A non-editable field indicating the name of the subclass.
Note: Click the Owner hot link to open the Specification dialog for that element.
Stereotype
Specify a stereotype to apply to the relationship.
Visibility
Specifies the visibility of the generalization. Visibility options are
■ Public - Visible to any class.
■
Protected - Visible to this class, any subclasses of this class, and any designated
friend classes.
■
Private - Visible only to this class and any designated friend classes.
■
Implementation - not visible to any other classes.
Friendship Required
Specifies that the supplier class has granted rights to the client class to access its
non-public members. In the case of a generalization, the subclass is granted friend
access right to superclass members.
Effect on code generation: This field currently has no effect on code generation.
Virtual Inheritance
Specifies that only one copy of the base class will be inherited by descendants of the
subclasses.
Excluding Elements
In addition to promoting and demoting, you can also exclude certain inherited
elements (the same set that can be promoted/demoted) from a capsule subclass or
protocol subclass.
An excluded element is removed from the subclass diagram or properties. Note that
for structure elements (ports and capsule roles), the excluded element will still be
inherited in the code of the subclass, since these elements are generated as members of
the superclass and automatically inherited by the subclass. This means, you should
not reuse the name of any excluded element or you may cause a name conflict at
compile-time.
The arrowhead points to the supplier class. In this example, class A is dependent on
class B.
Naming
Use the relationship name to identify the type or purpose of the relationship.
Valid Applications
You can draw a dependency relationship between logical packages.
Dependency Specification
The dependency relationship indicates that the client class depends on the supplier
class to provide certain services. One class may use another class in a variety of ways.
Typically, a dependency relationship indicates that the operations of the client access
members (operations or attributes) of the supplier. Dependencies can also be drawn
between packages.
You can change properties or relationships by modifying the icon on the diagram or
by editing the specification.
You can also view the specification by double-clicking on the name of the dependency
relationship in the Relations tab of the Class Specification.
The associated diagrams or specification are automatically updated.
The Dependency Specification contains the following tabs: General, Files.
Name
A name for the dependency relationship.
Class
A non-editable field listing the client class.
Note: Click the Class hot link to open the Specification dialog for that element.
Stereotype
Specifies a stereotype to attach to the dependency.
Friendship Required
A check box indicating whether the client class should be generated as a friend of the
supplier to provide access to non-public members on the supplier.
Effect on code generation: This field currently has no effect on code generation.
Export Control
Specifies the visibility of the dependency. Visibility options are
■
Public - Visible to any class.
■
Protected - Visible to this class, any subclasses of this class, and any designated friend
classes.
■
Private - Visible only to this class and any designated friend classes.
■
Implementation - Not visible to any other classes.
Effect on code generation: None.
Multiplicity from
Describe the multiplicity of the client side of the relationship.
Effect on code generation: None.
Multiplicity to
Describe the multiplicity of the supplier side of the relationship.
Effect on code generation: None.
Naming
Use the relationship name to identify the type or purpose of the relationship.
Valid Applications
You can draw a realize relationship between a ClassInterface and a Component
Interface. The relationship between a component and an interface can not be drawn
explicitly. It is created when an interface is assigned to a component through the
browser or a specification editor.
General Tab
Name
A name for the Realize relationship.
Documentation
Use to describe the Realize relationship.
Inserting Dependencies
A dependency relationship specifies that a change in the specification of one element
may affect another element that uses it, but not necessarily the reverse. A dependency
relationship models dependencies that have not been implicitly captured by the other
types of relationships in your model.
From the Context menu in the Relations tab, you can insert dependencies for the
following:
■
Capsule
■
Class
■
Protocol
■
Actor
To insert a dependency:
1 In the Relations tab for a Class, Capsule, or Protocol Specification dialog box,
right-click and select Insert Dependency.
2 Double-click to select an item from the drop-down list.
3 Click OK.
In the Relations tab, all dependency relationships begin with depends on.
Inserting Generalizations
Generalizations are significant in that they affect from which object we inherit (such
as, attributes and operations). From the Context menu In the Relations tab, you can
insert generalizations for the following:
■
Capsule
■
Class
■ Protocol
■ Actor
To insert a generalization:
1 In the Relations tab for a Class, Capsule, or Protocol Specification dialog box,
right-click and select Insert Generalization.
3 Select Absorb all current superclass properties if you want the subclass to inherit
all existing properties of its superclass. Select Exclude new superclass properties
if you do not want the subclass to inherit certain properties (such as state machine,
capsule structure, and protocol signals) defined in the superclass. This is useful for
those situations when your subclass has a state machine and you want to merge
the state machines rather than blindly inheriting the superclass state machine. You
can initially exclude the superclass elements, and then gradually re-inherit them as
you edit your state machine.
Note: To exit from this pop-up without making a selection, click ESC.
Inserting Realizations
A realization relationship is a form of generalization in which only behavior is
inherited. From the Context menu in the Relations tab, you can insert realizations for
the following:
■
Class
■
Protocol
■
Actor
In the Relations tab, the name of a realization relationship begins with Realize.
Note: The size of the drop-down list is the width of the End Class column. If you
cannot see the full name of the items in the list, widen the End Class column in the
dialog box.
When modifying the End Class, the pop-up list contains only those objects of the
same type as the selected object:
❑
in a Class Specification dialog box for a class, the list only contains classes
❑
in a Class Specification dialog box for an actor, the list only contains actors
❑
in a Capsule Specification dialog box, the list contains capsules
❑
in a Protocol Specification dialog box, the list contains protocols
2 Select an item from the list.
Note: The diagram will be updated only if the relation already existed in the diagram.
There are two components in the Component View: one for C and one for C++. Each
produces an executable that yields the same output when run.
Figure 30 shows the Component Specification dialog box for the C++ component.
The Environment box indicates that this component does not use the C++ and code
generator.
The Type box indicates that a library will be built. The Hello World model has no
Capsules or Protocols in the Component library and the generated library will contain
no dependencies on the runtime system. This is beneficial because:
■
it can be used by non-Rational Rose RealTime applications
■
it is usable within Rational Rose RealTime applications with some limitations, as if
you link with external code.
Figure 31 shows the Operations tab for the CppMain class in the Hello World model.
For execution of the application to begin, code must be provided to call:
int main (int argc, const char * const * argv)
or
int main ()
Note: In C++, a class can have nested classes with state machines, and in turn, they
may also have state machines.
The drop-down list displays all available operations that are stereotyped <<trigger>>
for the selected class. The item << Create a new trigger >> will create a new operation
with a stereotype of trigger.
If there is only one operation stereotyped as trigger and no other operation has the
same name, the operation appears in the Model View tab without a signature (see
NewOperation3 in Figure 33).
Note: You cannot create events that do not have names. You can specify a name from
the drop-down list or you can type another name. However, code generation will fail
if the name does not match the name of a trigger stereotyped operation.
In the Hello World model, the State Machine diagram for the CppHello (C++) and
CHello (C) classes are identical (see Figure 35).
Triggers
A trigger is a stereotyped operation used to trigger a transition in a class state
machine. Triggers must have the following properties:
■
be public
■ have a stereotype of <<trigger>>
■
return void
■
have no arguments
■
have no detail code (code generation ignores arguments and detail code for a
trigger operation on a data class)
As a result of the properties of a trigger, there is no concept of rtdata/RTDATA in the
triggered transition. Also, there is no target observability for data class state digrams
(for example, no passive class state monitors). Data class state machines are designed
to work in a noRTS target environment and do not depend on the toolset or
TargetRTS, which precludes the ability to do target observability.
Some functions can be executed in multiple triggers; the code is copied to multiple
trigger functions. If there is a lot of code in a transition, and you want to copy this
code, create an operation and then call this operation in the transition.
In C, you can have implementation visibility so that you can build a class where the
implementation is separate from the state machine.
Considerations
When using Code Sync, consider the following:
■ Code Sync cannot be used to create, delete, or rename model elements, or to
otherwise make structural changes to the model. You must make these kinds of
modifications using the Rational Rose RealTime toolset.
■
If you modify any generated code externally (that is, outside of the Rational Rose
RealTime toolset), do not use the toolset to run the externally built executable until
all Code Sync changes have been reconciled.
■ If you modify the generated code manually, Clearmake cannot provide complete
traceability back to model files, and it cannot provide wink-in. This means that
generated code that has been manually modified is no longer considered a derived
object, but rather a view-private file.
#ifndef CppHello_H
#define CppHello_H
#ifdef PRAGMA
#pragma interface "CppHello.h"
#endif
#include <RTSystem/cpp.h>
class CppHello
{
protected:
// {{{RME tool 'OT::Cpp' property 'ProtectedDeclarations'
// }}}RME
private:
// {{{RME tool 'OT::Cpp' property 'PrivateDeclarations'
// }}}RME
struct RTState_CppHello
{
inline RTState_CppHello( void );
inline ~RTState_CppHello( void );
unsigned char state;
};
RTState_CppHello rtg_state_CppHello;
public:
// {{{RME classAttribute 'count'
int count;
// }}}RME
// {{{RME tool 'OT::Cpp' property 'GenerateDefaultConstructor'
CppHello( void );
// }}}RME
private:
// {{{RME operation 'T0()'
void T0( void );
// }}}RME
// {{{RME operation 'T1()'
void T1( void );
// }}}RME
// {{{RME operation 'N1()'
void N1( void );
// }}}RME
public:
void E1( void );
};
#endif /* CppHello_H */
// }}}RME
CPPHello.cpp (C++)
#if defined( PRAGMA ) && ! defined( PRAGMA_IMPLEMENTED )
#pragma implementation "CppHello.h"
#endif
#include <RTSystem/cpp.h>
#include <CppHello.h>
// }}}RME
Using Constructors
A state machine must be initialized before it is used, which may cause one or more
initial transitions to fire. Since these transitions may cause operations on the class for
it’s state machine, initialization must occur after the class is constructed.
Note: You can specify when that state-machine is initialized. A state machine may
also be re-initialized.
You can create a trigger of your own to initialize the state machine.
Note: The rtg_init1 reference in the generated code for the Hello World model causes
the automatic initialization of state machine in the constructor.
Example
Figure 39 shows a an example of a state diagram containing transition ee; a
self-transition that has a trigger for an event that none of the substates can handle.
When that event occurs, the self transition will fire, and then go to H* (deep history)
meaning that it will revert to the last active substate. The result is to perform event
handling without changing the state of the system.
Parameterized Classes
A parameterized class describes a group of classes.
This corresponds to the preface of the basic_string template from the standard
template library.
template < class Ch, class Tr = char_traits< Ch >, class A = allocator< Ch > >
Depending on the information on the C++ tab, the generator will support templates
based on classes where the ClassKind property is class, struct or union.
Note: Enumerations and typedefs are not supported.
Parametrized classes may define attributes, operations and nested classes. They may
participate in dependency and generalization relationships. They may not be the
target of navigable associations, nor can they be the association class of any
association. They can only be the target of instantiation relationships.
Relationships
You can draw the following relationships:
Instantiated Classes
An instantiated class is a class formed from a parameterized class by supplying actual
values for parameters. You use an instantiated class to select a member of the set of
classes described by a parameterized class.
Relationships
You can draw the following relationships for instantiated classes:
Toolset Dependencies
You will need to address the following issues:
■ Import Generalization Relationships
Rational Rose has a C++ property named InstanceArgument that you must import
into a property of the same name and associated with the OT::Cpp tool in Rational
Rose RealTime.
■
Relax Rules For Actual Arguments
Rational Rose uses the contents of Name column of the actual arguments of an
instantiated class. Because these arguments can be any legal C++ type or value
expression, Rational Rose RealTime cannot modify the names when importing a
Rational Rose model, nor can it place any restrictions on the names entered.
Note: Parameter names are validated whenever the class Type changes, or when
parameters are copied from an instantiated class to a more restrictive context. The
illegal characters are replaced by underscores.
■
Allow Deletion of Actual Arguments
If you copy an actual argument from one instantiated class to another, you cannot
delete it from the source class.
207
Creating a complete capsule structure definition may consist of any of the following
basic steps:
■
Adding a Capsule Role
■
Creating a Port
■ Connecting Ports on Capsule Roles Together
UML Options
You can use the popup menu to toggle the following UML options:
Selector Tool
Selects objects for moving, resizing, and so forth.
Zoom Tool
Zooms in on or out on diagrams.
Text Tool
Adds text anywhere in the structure diagram.
Note Tool
Annotates the diagram with textual notes. This is useful for marking up the diagram
with explanations, review comments, and so forth. You can drag and drop a diagram
or external document from the browser onto a note. Notice that the name of the
diagram or external document is underlined. If you double-click on the note, the
diagram or external document is opened. You can undo and redo this command.
Constraint Tool
Adds UML constraints to the diagram. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
Port Tool
Adds new ports to the capsule class structure. Ports can be placed either in the
internal structure (inside the black interface boundary, which makes them protected,
or on the structure interface, which makes them public.
A popup menu appears on the capsule role allowing you to select the protocol class of
the port from the list of available protocol classes (that is, all protocol classes in the
model). The first entry in the popup menu is Create a New Protocol which creates a
new protocol class called ‘NewProtocol1’.
Protected ports are automatically created as end ports. Public ports are created as end
ports by default.
Connector Tool
The connector tool is used to wire ports together. Usually connectors bind ports on
different contained capsule roles together within the container capsule class.
Connectors can also bind internal end ports of the container class to other ports.
Interface end ports can only be bound within the context of a container class.
Only compatible ports can be connected together. Compatible ports are usually two
ports of the same protocol class, one of which is conjugated.
Creating a Port
There are four different ways to add a port to a capsule:
■
Drag and drop a protocol class name from the model browser onto the capsule
structure diagram.
■
Draw an aggregation between a capsule class and a protocol class on a class
diagram.
Port Specification
The Port Specification provides control over information about ports on capsules.
The Port Specification contains two tabs: the General Tab and the Files Tab.
General Tab
Name
The port is referenced by a name. The default name provided when the port is first
created is based on the protocol name. In addition to appearing on the structure
diagrams, the port name is used by the behavior of the capsule containing the port. To
send and receive messages, the capsule's behavior references the port name in
detailed code, and in transition trigger events.
Protocol
Specifies the protocol class to be used for the port. The protocol class (together with
the Conjugation check-box) determines the set of messages that can be sent through
this port (the out set), and the set of messages that can be received (the in set). The
field has a pull-down menu to select from the available protocol classes in the model.
The pull-down list always includes the service protocols for communicating with the
target services library.
The Open button opens the Protocol Specification for the selected protocol class.
Note: If the Protocol box contains a value, the corresponding label becomes a hot link
to the Specification dialog for that protocol.
Cardinality
Specifies the number of instances of the port that will appear at run-time. The port is
implemented as a member variable of the containing capsule. The variable may be an
array of ports, connected to multiple ports on the other end of the connector. In this
case, the port name points to an array of port instances. The Cardinality specifies the
size of the array. Not all port instances in the array are necessarily connected.
Individual port instances are referenced by indexing into the array. See the message
send syntax in the Programmer’s Guide for details. The Cardinality can be specified
with an integer value or as the name of a constant defined within the model.
End Port
Indicates that the port is an End Port, capable of sending and receiving messages. End
Ports provide a connection between the behavior of the capsule containing the end
port and the outside world. If this check-box is not checked, then the port is a relay
port. Relay ports cannot be protected, they must be public.
To send messages, a capsule must have end ports. The end port's protocol defines the
set of messages that can be sent.
To receive messages and process them within the capsule's behavior, the capsule must
have end ports. The end port's protocol defines the set of messages that can be
received.
Messages received on relay ports are not visible to the behavior of the capsule
containing the port. Relay ports are intended to be connected to capsule roles
contained within the capsule. Relay ports take messages from outside of the capsule
and relay them through the capsule's encapsulation boundary to other capsules
contained inside.
Wired
Indicates that the port is a wired port. Wired ports are connected to other wired ports
using connectors (via the Connector tool in the capsule structure diagram).
Non-wired ports are connected to other non-wired ports by name.
The connection of wired ports is done automatically based on the system structure.
Wired ports on fixed capsules are connected at initialization time. Wired ports on
optional and plug-in capsules are connected dynamically when the capsule is
instantiated or plugged-in.
Protected
Determines whether the port is visible outside of the capsule boundary. If the port is
not protected, it is public. Public ports are part of the capsule interface and are visible
to other capsules. By default, ports are protected.
Notification
When selected, the port will receive rtBound and rtUnbound messages from the
services library when ports get connected and unconnected.
Note: rtBound is sent at system priority and rtUnbound is sent at background
priority.
Registration
Specifies the type of registration for the port. This option is only enabled for
non-wired ports. Non-wired ports are registered by name with a name service that
performs the connection. Connections are made between protected non-wired ports
(service clients) and a single public non-wired port (the service provider). There are
three registration modes:
■
Automatic - Automatic registration by name at the time the capsule is initialized.
In this case, when the capsule is initialized, a non-wired protected port is
connected to any non-wired public port of the same name.
■
Application - Dynamic registration by a name specified by the capsule's behavior.
■
Automatic (locked) - Automatic registration by name at the time the capsule is
initialized. Application calls to the following will fail and set the register to
RTController::badOperation:
❑
deregister
❑
deregisterSAP
❑
deregisterSPP
❑
registerAs
❑
registerSAP
❑
registerSPP
In this case, when the capsule is initialized, a non-wired protected port is
connected to any non-wired public port of the same name. The port is not
connected at initialization time. It is connected when the capsule's behavior
invokes a service function to register the port by a specified name. The same port
may be registered under different names at different points in the model execution.
This is determined by the registration method selected.
Files Tab
A list of referenced files. You can insert and delete references to files or URLs.
You can also link external files to the Specification for documentation purposes.
Name
Specifies the name for the port role.
Note: If the Name box contains a name, the corresponding label becomes a hot link to
the Specification dialog for that port.
Protocol Class
Specifies the protocol class for the port role.
Note: If the Protocol Class box contains a protocol name, the corresponding label
becomes a hot link to the Specification dialog for that protocol.
Conjugated
A conjugated port is one in which the standard protocol class definition of in and out
signals is reversed. That is, on a conjugated port, the protocol class out signals become
the port's in signals, and the protocol class in signals become the port's out signals.
This enables two ports of the same protocol class to be connected together without
having to define a separate reverse protocol. A connection can be made between two
ports of the same protocol by conjugating one of the ports. This is the most common
way of establishing communicating between two ports.
Cardinality
The Cardinality field defines the maximum number of port instances that can exist in
this role at any given time. If the role is Fixed, then the number of instances of the role
instantiated at run-time will be exactly the number defined in the Cardinality field. If
the role is Optional, then up to <Cardinality> instances may be created at run-time.
Documentation
Specifies descriptive text about the port role.
General Tab
Name
The name of the capsule role within the container capsule structure. The capsule role
name may be used in the detailed code of the container capsule.
Class
The Class field defines the Capsule Class to be used in instantiating this role. If the
capsule role is an Optional role or a Plug-In role, then subclasses of the specified Class
may also be instantiated into this role, but only if the substitutable flag is checked.
Substitutable
This check box indicates whether subclasses of the specified capsule role's class can be
instantiated into this role. This may happen in one of two ways:
1 If the capsule role is Optional, the container capsule may instantiate a subclass of
the specified capsule class into the capsule role.
2 A subclass of the container capsule may override the class of the inherited capsule
role.
Fixed
If the fixed check-box is checked, then a capsule of the specified class is automatically
instantiated into the role in every instance of the container capsule at run-time. A
number of instances equal to the specified cardinality will be created at initialization
time.
Optional
If the optional check-box is checked, then the capsule role is instantiated under the
program control of the container class. The container class must explicitly instantiate
the capsule role within the detailed code of the container capsule state machine. This
is done using the incarnate function of the Frame service.
Plug-In
If the Plug-In check-box is checked, then the capsule role is never directly instantiated,
but rather an already existing instantiation from another capsule decomposition is
imported into the role. That is, an existing capsule is dynamically “plugged in” to the
specified role under the program control of the container class. The container class
state machine must explicitly request the plug-in of a capsule at run-time within the
detailed code. This is done using the import function of the Frame service.
Connector Specification
The Connector Specification provides control over the properties of a connector in a
capsule structure diagram. Connectors connect ports together to enable
communication among capsules.
There are two tabs: General and Files.
General Tab
Name
The name of the connector. Connector names are not usually displayed on the
structure diagram and are not significant in the generated code.
Delay
Specifies a communication delay across a connector. This field is for documentation
purposes only. There is no validation or calculation of actual communication delays at
run-time.
Cardinality
Specifies the number of connectors indicated by a connector line. When a connector is
used to connect ports with cardinality > 1 or ports on capsule roles with cardinality >
1, the connector cardinality should match the cardinality of the port/capsule
combination on either side of the connection.
Sequence Overlays
You can also overlay Message Flow Arrows from a Sequence diagram on top of the
Collaboration dialogs by selecting Sequence Overlays... from the popup menu. Only
"Request" actions - Call and Send - are shown. Create and Destroy messages are not.
Messages are only displayed when there is an existing Association Role or Connector
to bind them to. Messages To or From the Environment are not displayed.
Code Generation
There is no code generated from the collaboration diagram. It is for communication
purposes only. The capsule structure diagram is a specialized form of collaboration
diagram with specific constraints that enable code to be generated to implement the
communication patterns shown in the capsule structure.
Selector Tool
Selects objects for moving, resizing, and so forth.
Zoom Tool
Zooms in on a portion of the diagram. Select the tool and then click on the part of the
diagram you want to zoom in on.
Text Tool
Adds text anywhere in the structure diagram.
Note Tool
Annotates the diagram with textual notes. This is useful for marking up the diagram
with explanations, review comments, and so forth. You can drag and drop a diagram
or external document from the browser onto a note. Notice that the name of the
diagram or external document is underlined. If you double-click on the note, the
diagram or external document is opened. You can undo and redo this command.
Constraint Tool
Adds UML constraints to the diagram. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
Name
The name of the classifier role within the collaboration.
Stereotype
A stereotype label for the association.
Classifier
Specifies a class to fill this role.
Note: If the Classifier box contains a class, the corresponding label becomes a hot link
to the Specification dialog for that class.
Multiplicity
The multiplicity field defines the maximum number of instances that can exist in this
role at any given time.
Documentation
Use to describe this classifier role.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
General Tab
Name
The name of the association role within the collaboration.
Association
Specifies a class to fill this role.
Multiplicity
The multiplicity field defines the maximum number of instances that can exist in this
role at any given time.
Documentation
Use to describe this association role.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
229
You can include the following types of behavioral elements to a capsule behavior
diagram:
■
States
■
Transitions
■ Choice points
None of these elements are required. A capsule does not have to have any states or
transitions. If the capsule has any interfaces (end ports) in its structure definition, then
it must have a state machine to deal with events arriving on its interfaces.
Creating a complete capsule state diagram definition can consist of any of the
following basic steps:
■ Adding a State
■
Adding a Choice Point
■
Drawing Transitions Between States
■
Defining State Transition Trigger Events
■
Joining Transitions
■
Creating Nested States
Selector Tool
Select objects for moving, resizing, and so forth.
Zoom Tool
Use to zoom in on a portion of the diagram. Click on the tool and then click on the
part of the diagram you want to zoom in on.
Text Tool
Adds text anywhere in the structure diagram.
Constraint Tool
Adds UML constraints to the diagram. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
State Tool
Adds a state to the diagram. Click on the diagram to place a new state at the selected
location.
States have default names, such as 's1', when initially drawn. To change the name,
click on the state and hit the BACKSPACE key to delete the default name, then type the
new name.
State Specification
The state specification allows you to enter details about the state.
The state specification dialog contains the following tabs: General, Entry Actions, Exit
Actions, Files.
Note: If this state is a top state, an initial point, or a final state on a data or protocol
class, then it will not contain any Entry Actions or Exit Actions tabs.
General Tab
Name
The name of the state. The state name appears on the state diagram, and will be part
of the generated code for any capsule class. It will also be used in the verification of
any sequence diagrams involving the capsule if the sequence diagram used as the
specification contains state information.
Class
The class whose state machine this state is a part of.
Code
A Code Editor used to enter the detail code that will be executed upon entry to or exit
from the state.
This field may also be modified from the generated code and captured into the model
using the Code Sync feature. For more information, see Using Code Sync to Change
Generated Code on page 531.
Transition Specification
The transition specification is used to edit the properties of a state transition. There are
up to four tabs: General, Triggers, Actions, and Files.
If the transition is an initial transition, or is not the originating segment of a joined
transition, then the Triggers tab is not displayed.
General Tab
Name
The name of the transition. If the transition is part of a capsule state diagram, the
transition name will appear in the generated code for a capsule.
Internal
This check box indicates that a self-transition should not cause an exit from the state
when triggered. The result is that when an internal transition is triggered, no exit or
entry code is run.
Triggers Tab
Triggers List
The triggers list is used for Defining State Transition Trigger Events. The triggers list
contains the list of individual trigger events. Each event consists of a port name, a
signal or set of signals, and an optional guard condition. The Transition Events tab
contains the list of events that can trigger the transition. The list is an ‘OR' list,
meaning that the receipt of any one of the signals in the event list will cause the
transition to fire. There is no ‘AND' definition of event triggers (since only one
message is processed at a time).
Actions Tab
Code
Contains a Code Editor for defining detailed action code.
This field may also be modified from the generated code and captured into the model
using the Code Sync feature. For more information, see Using Code Sync to Change
Generated Code on page 531.
For capsules, the transition action code will be output as part of the generated code,
and the code will be executed when the transition is triggered at run-time.
Transition actions defined in state diagrams for protocols or regular (non-capsule)
classes is not generated or executed. It is for information purposes only.
Files Tab
The Files tab allows for linking external files to the transition.
General Tab
Contains standard specification dialog items.
Condition Tab
Contains a Code Editor for entering the code that determines which branch of the
transition will be taken. The code must return a true or false value (false is zero and
true is non-zero).
This field may also be modified from the generated code and captured into the model
using the Code Sync feature. For more information, see Using Code Sync to Change
Generated Code on page 531.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
General Tab
Name
The default name for the initial state is Initial and should not be changed.
Class
A non-editable field indicating the class whose state machine the initial state is part of.
Documentation
A description of the initial state.
General Tab
Name
A name for the junction point. Most junction points are given automatically generated
names.
Continuation
This selection specifies the semantics for how the state history will be used when there
is no continuing transition. There are three options:
■
Default - specifies that the default (initial) transition should be run.
■
History - specifies that the state should return to shallow history.
■
Deep History - specifies that the state should return to deep history, meaning that
all substates also return to history. This is the behavior for all capsule state
machines, so it is automatically selected.
Note: The default for capsule state machines is to always go to deep history, so deep
history is automatically selected for capsule states, and the selections are grayed out.
Externally Visible
This check box indicates whether the junction point is visible on the outside of the
state boundary.
Ports List
The Ports list contains end ports that currently exist in the Collaboration Diagram for
a capsule. Only those end ports that have In signals appear in this list because they
are the only ones capable of receiving messages.
Note: You cannot specify triggering events until you define the end port on which the
event will arrive.
A port that is not an end port, which is then made into an end port, will not appear in
the Ports list until the EventGuard Specification dialog box closes.
Signals List
When you select a port from the Port list, the Signals list will contain all of the
in signals from that port, as well as the universal signal (*), rtBound, and rtUnbound.
Use the universal signal to specify that any signal received on the selected port will
trigger the transition.
If there is more than one port selected in the Port list, and all the selected ports use the
same protocol, or use protocols that derive from a common protocol, then signals
from that common protocol appear in the Signal list. Otherwise, only the universal
signal (*) appears in the Signal list. You can select the universal signal if it is the only
signal selected. If other signals were selected previously, they will no longer be
selected.
The signals for the selected port (the signals that can be received on that port)
display in the Signals list.
Note: Multiple ports from the ports list can be selected, but when selecting
multiple ports, the signals are only displayed if all ports share the same protocol.
The signals list displays signals that can be received by the currently selected end
port, as well as a default universal signal selection (*).
6 Select one or more signals in the Signal list.
Multiple signals from the signals list can be selected. Any one of the selected
signals will act as a trigger for the transition.
7 Specify code for a guard condition in the Guard Code area, if required.
8 Click OK.
Transitions containing code are shown with the arrowhead filled in black.
The initial transition has a default name of 'Initial'. You can change the name by
selecting the label and typing in it.
Note: If you select a label, the tether to that label displays for a short time only. To
view the tether for longer periods, press and hold the left mouse button. The tether to
the label will display for as long as you hold the left mouse button. If you start to drag
the label, the tether is replaced with a tether and tracking box.
State Diagrams
Note: If you select a label, the tether to that label displays for a short time only. To
view the tether for longer periods, press and hold the left mouse button. The tether to
the label will display for as long as you hold the left mouse button. If you start to drag
the label, the tether is replaced with a tether and tracking box.
Figure 53 shows the State Diagram for the parent capsule MyParent.
From the Filter submenu, select Show Transition Code to display the Action code for
all transitions in the current state diagram.
These filter options are specific to the current State Diagram; setting these options in
one State Diagram does not set these options in other State Diagrams.
Note: You can change the default value for displaying transition triggers and code for
new State Diagrams by clicking Tools > Options and setting Trigger labels and Code
labels in the State Diagram area in Filtering tab.
Descriptions
Transition Type
Specifies the type of transition entering the selected state (the first column in the
Transition tab). The transition types are:
■
Internal Transition - A transition that does not cause a change in state. This
type of transition is not visible outside the state boundary.
■
External Transition - A transition that causes a change in state. This type of
transition is visible outside the state boundary.
■
Internal Self Transition - This type of self transition does not cause an exit
from the state when triggered and no exit or entry code is run. This means that the
transition executes without exiting or re-entering the state in which it is defined.
Also, the exit and entry actions of all states which where exited and re-entered are
not executed. These kinds of transitions are similar to having global operations
defined on a state machine; when they are taken do not change the state of the
system. This type of transition is not visible outside the state boundary.
Identifying Self Transitions on the Transitions Tab in the State Specification Dialog Box 255
■
External Self Transition - For this type of self transition, the exit and entry
code is executed for the state on which it originates and terminates. This type of
transition is visible outside the state boundary.
Name
Assigned to each transition entering the selected state. This name appears in the
generated code for a capsule.
Event
Contains a list of individual trigger events. An event is an occurrence of a stimulus
that causes a state transition. Each event consists of a port name, a signal or set of
signals, and an optional guard condition. The data for an event is a UML string
indicating the ports and signals that trigger this transition. The text that appears in
this column is similar to that seen in the pop-up ToolTip for the transition, excluding
the Guard code and the Action code.
To add new events, right-click in the list area and Open Specification, then right-click
in the Triggers tab in the Transition Specification dialog box and click Insert. You can
now select the ports) and signals that will act as trigger events.
End State
Indicates the name of the final execution state that the transition ends on, based on the
completion of the current state. For internal and external self transitions, the end state
will be the current state.
257
Modeling Using Activity Diagrams
Activity Diagrams allow you to model dynamic behavior in a model. Typically, you
use an Activity Diagram to model the discrete stages of an object’s lifetime, and the
sequence of activities in a process.
Activity Diagrams provide a way to model the dynamic aspects (workflow) of a
business process or system, and to model the dynamic behavior of individual classes,
or any other type of object. For example, you can use Activity Diagrams to model
code-specific information, such as a class operation. Activity Diagrams are available
for Use Cases, Logical Packages, actors, classes, capsules, packages, interfaces, and
operations for classes and Use Cases.
Activity Diagrams are very similar to a flowchart because you can model a workflow
from activity to activity. An Activity Diagram is a special type of state machine in
which some of the states are activities, and some of the transitions are implicitly
triggered by completion of the actions in the source activities.
Additionally, Activity Diagrams can show the sequences of states that an object goes
through, the events that cause a transition from one state to another, and the actions
that result from a state change. Each state represents a named condition during the life
of an object during which it satisfies some condition, or waits for some event.
Activity Diagrams
Activity Diagrams can model many different types of workflows. For example, a
company could use Activity Diagrams to model the flow for an approval of orders or
to model the paper trail of invoices. An accounting firm could use Activity Diagrams
to model any number of financial transactions. A software company could use
Activity Diagrams to model a software development process.
Typically, an Activity Diagram contains one Start State and multiple End States.
Transitions connect the various states on the diagram. The workflow on an Activity
Diagram stops when a transition reaches an end state.
Each state and activity represents the performance of a group of events or actions in a
workflow. After the state or activity completes, the flow of control moves to the next
state or activity through a transition. If an outgoing transition is not clearly triggered
by an event, then it is triggered by the completion of the contained actions inside the
activity.
A unique Activity Diagram feature is a swimlane that defines who or what is
responsible for carrying out a given state or activity. It is also possible to place objects
on Activity Diagrams.
Note: You can attach Activity Diagrams to most model elements in the Use Case or
Logical Views.
Name
Specifies the name of the currently selected Activity Diagram.
Documentation
Describes the purpose or intent of the Activity Diagram. The description can include
information such as the essential behavior of the diagram. The information you type
in this field is not displayed in the Activity Diagram.
Name
Specifies the name of the currently selected State/Activity diagram.
Stereotype
Specifies a keyword that further defines the classification of the diagram. A stereotype
represents the subclassification of a model element. Some stereotypes are already
predefined, but you can also define your own to specify new modeling types.
Owner
Specifies the model elements that own the selected State/Activity Diagram.
Context
Specifies a view for a related set of modeling types.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Activity History
The history icon, , provides a mechanism to return to the most recently visited
state or activity when transitioning directly to a state or activity with substates.
History applies to the given level in which it appears. History may also be applied to
the lowest depth of nested states. You may place an asterisk in the name field of the
history state to designate the lowest depth.
To delete history icons, use Cut from the toolbar or click Edit > Delete.
Activities 265
The border of the target activity becomes bold as the nested activity moves over it.
Note: After you drop an activity, the boundaries of the super-state or super-activity
enlarge to accommodate the nested element. If the mouse pointer is positioned over
more than one state or activity at the same time, the element at the deepest level of
nesting is considered the target. You can select multiple activities and nest them as a
group.
Name
Specifies the name for the currently selected activity.
Stereotype
Specifies a keyword that further defines the classification of the model element. A
stereotype represents the subclassification of a model element. Some stereotypes are
already predefined but you can also define your own to specify new modeling types.
To view stereotypes on the Activity Diagrams, click Tools > Options, select the
Diagram tab, and click Label, Decoration and label, Decoration only, or Icon in the
Stereotype box. Label displays the stereotype name in angle brackets (for example,
<<stereotype>>). Decoration displays a graphic marker such as highlighting an
icon or tool. Icon displays the graphical representation, if any.
Context
Specifies a view for a related set of modeling types.
Documentation
Describes model elements or relationships. The description can include information
such as the constraints, purpose, and essential behavior of the element. The
information you type in this field is not displayed in the Activity Diagram.
State/activity history
Specifies whether to return the most recently visited state or activity when
transitioning directly to a state or activity with sub-states or sub-activities. Set this
option to apply history at the state or activity level.
History provides a mechanism to return to the most recently visited state (or activity)
when transitioning directly to a state (or activity) with sub-states (sub-activities).
History applies to the level in which it appears. It may also be applied to the lowest
depth of nested states (or activity).
Type
Displays the action specified in the Action Specification dialog. The following actions
on activities can occur:
■
Entry - The task is performed when the object enters the activity.
■
Exit - The task is performed when the object exits the activity.
■ Do - The task is performed while in the activity and must continue until exiting the
activity.
■
Event - The task triggers an event only when a specific event is received.
The type of action determines the options that are available in the dialog box.
Double-click on an action to open the Action Specification dialog for the selected
action. If there are no actions listed, right-click on the Actions tab and click Insert.
Action Expression
Displays the timing option that specifies when to carry out an action and the types of
actions that are carried out.
Event
Specifies the names of all the events for transitions associated with the activity.
An event causes a state transition. You do not have to uniquely label events because
one event can cause a transition to many different states, activities, decisions, or
synchronizations.
End
Specifies the target state or activity for transitions.
Name
Specifies the swimlane name where the enclosed activity resides.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Actions
Each state and activity on an Activity Diagram can contain any number of internal
actions. An action is a task that takes place while inside a state or activity.
Within a state or activity, there are four possible types for an action:
■
on Entry
■ on Exit
■
do
■
on Event
For example, Figure 64 shows that when entering the AwakenByLight state, the entry
action (On Entry) turns on the light. Next, the do action changes the behavior of the
state so that it blinks five times. Upon exiting the exits the AwakenByLight state, the
exit action (On Exit) turns off the light.
Actions 269
Action Specification Dialog
An Action Specification dialog enables you to display and modify the action
properties in an Activity Diagram.
To open the Action Specification dialog, double-click on an action on the Actions tab.
The Action Specification dialog has the following tabs:
■
Detail, see Action Specification Dialog - Detail Tab
■ Files, see Action Specification Dialog - Files Tab
When
Specifies a timing option to carry out for the selected action.
On Event
The On Event parameters are available only when you set the On Event timing
parameter in the When box.
■
Event - In an Activity Diagram, an event is an occurrence that can trigger a state
transition. Type the name of the event that will trigger the action.
■
Arguments - Specifies any optional arguments associated with the event.
■ Condition - Specifies a conditional Boolean expression.
You can use an On Event action rather than a self-transition because self-transitions
trigger all the actions associated with a state, whereas state and activity actions handle
internal state and activity transitions. This means that you can process an internal
event without triggering the entry and exit actions.
Name
Specifies a name of the Action or Send Event. This name appears on the state or
activity on the Activity Diagram.
Send arguments
Specifies any arguments for a send event. One or more arguments can accompany a
send event.
Send target
Specifies any targets for the send event. A target is any object that will receive the
transition event.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Decisions
A decision represents a specific location on an Activity Diagram where the workflow
may branch based upon guard conditions. There may be more than two outgoing
transitions with different guard conditions, but for the most part, a decision has only
two outgoing transitions determined by a Boolean expression.
Decisions 271
Figure 65 shows an example of using a decision on an Activity Diagram.
Note: Decisions only appear on Activity Diagrams; they do not appear on the Model
View tab in the browser.
Name
Specifies the name for the selected decision.
Owner
Specifies the owner of the decision; the object that owns this element in the model.
Documentation
Describes model elements or relationships. The description can include information
such as the constraints, purpose, and essential behavior of the element.
Event
Specifies the names of all the events for transitions associated with the decision.
An event causes a state transition. You do not have to uniquely label events because
one event can cause a transition to many different states, activities, decisions, and
synchronizations.
End
Specifies the target state or activity for transitions.
Name
Specifies the swimlane name where the enclosed decision resides.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Transitions can only occur into an end state; however, there can be any number of end
states or activities that transition to a single end state. You can also have multiple end
states on an Activity Diagram.
For information on the State Specification dialog, see State Specification Dialog on
page 277.
Start State
A start state (also called an initial state) explicitly shows the beginning of a workflow
or execution of states on an Activity Diagram. You can have only one start state for
each Activity Diagram because each workflow/execution starts at the same location.
If you use multiple Activity Diagrams to model a single element for different views,
you can use the same start state as long as it is the same start state from the Model
View tab in the browser. When you model nested states or nested activities, you can
create one new start state for each context.
States
A state represents a condition or situation during the life of an object during which it
satisfies some condition or waits for some event. Each state represents the cumulative
history of its behavior.
Figure 69 shows a state for an Activity Diagram. The name of a state should be
unique to its enclosing class, or if nested, within the state.
States 275
Nested States
You can nest states to any depth level. Everything that lies within the bounds of the
nested state (sub-state) is referred to as its contents.
State History
The history icon, , provides a mechanism to return to the most recently visited
state or activity when transitioning directly to a state or activity with substates.
History applies to the given level in which it appears. History may also be applied to
the lowest depth of nested states. You may place an asterisk in the name field of the
history state to designate the lowest depth.
To delete history icons, use Cut from the Toolbar or click Edit > Delete.
Name
Specifies the name for the currently selected state.
Stereotype
Specifies a keyword that further defines the classification of the state. A stereotype
represents the subclassification of a model element. Some stereotypes are already
predefined, but you can also define your own to specify new modeling types.
Owner
Specifies the model elements that own the selected state.
Context
Specifies a view for a related set of modeling types.
Documentation
Describes model elements or relationships. The description can include such
information as the constraints, purpose, and essential behavior of the element. The
information you type in this field is not displayed in the Activity Diagram.
State/activity history
Specifies whether to return the most recently visited state or activity when
transitioning directly to a state or activity with sub-states or sub-activities. Set this
option to apply history at the state or activity level.
Note: Start States and End States do not have state or activity history.
History provides a mechanism to return to the most recently visited state (or activity)
when transitioning directly to a state (or activity) with sub-states (sub-activities).
History applies to the level in which it appears. It may also be applied to the lowest
depth of nested states (or activity).
History provides a mechanism to return to the most recently visited state (or activity)
when transitioning directly to a state (or activity) with sub-states (sub-activities).
History applies to the level in which it appears. It may also be applied to the lowest
depth of nested states (or activity).
Type
Displays the action specified in the Action Specification dialog. Actions on states can
occur:
■
Entry - The task is performed when the object enters the state.
■
Exit - The task is performed when the object exits the state.
■ Do - The task is performed while in the activity and must continue until exiting the
state.
■
Event - The task triggers an event only when a specific event is received.
The type of action determines the options that are available in the dialog box.
Double-click on an action to open the Action Specification dialog for the selected
action. If there are no actions listed, right-click on the Actions tab and click Insert.
Action Expression
Displays the name of the corresponding timing option that specifies when to carry out
an action for the selected state.
Event
Specifies the names of all the events for transitions associated with the state.
An event causes a state transition. You do not have to uniquely label events because
one event can cause a transition to many different states or activities.
It is possible for a state transition to have no associated event.
End
Specifies the target state or activity for transitions.
Name
Specifies the swimlane name where the enclosed state resides.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
When
Specifies a timing option to carry out for the selected action.
On Event
The On Event parameters are only enabled when you set the On Event timing
parameter in the When box.
■
Event - In an Activity Diagram, an event is an occurrence that can trigger a state
transition. Type the name of the event that will trigger the action.
■
Arguments - Specifies any optional arguments associated with the event.
■
Condition - Specifies a conditional Boolean expression.
You can use an On Event action rather than a self-transition because self-transitions
trigger all the actions associated with a state, whereas state and activity actions handle
internal state and activity transitions. This means that you can process an internal
event without triggering the entry and exit actions.
Name
Specifies a name of the Action or Send Event. This name appears on the state or
activity on the Activity Diagram.
Send arguments
Specifies any arguments for a send event. One or more arguments can accompany a
send event.
Send target
Specifies any targets for the send event. A target is any object that will receive the
transition event.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Synchronizations
Synchronizations let you to see a simultaneous workflow in an Activity Diagram.
Synchronizations visually define forks and joins representing a parallel workflow. For
example, a synchronization can have a single incoming transition with multiple
outgoing transitions, or have multiple incoming transitions with a single outgoing
transition.
Note: Synchronizations appear as a horizontal or vertical bar on an Activity Diagram
and may cross swimlanes. Synchronizations do not appear in the browser.
Synchronizations 281
Synchronization Specification Dialog
The Synchronization Specification dialog enables you to display and modify the
properties and relationships of a synchronization on an Activity Diagram.
To view the Synchronization Specification dialog, select a Synchronization on an
Activity Diagram and double-click.
The Synchronization Specification dialog has the following tabs:
■ General, see Synchronization Specification Dialog - General Tab
■ Transitions, see Synchronization Specification Dialog - Transitions Tab
■
Files, see Synchronization Specification Dialog - Files Tab
Name
Specifies the name for the selected synchronization (vertical or horizontal).
Owner
Specifies the owner of the synchronization; the object that owns this synchronization
in the model.
Stereotype
Specifies a keyword that further defines the classification of the model element. A
stereotype represents the subclassification of a model element. Some stereotypes are
already predefined, but you can also define your own to specify new modeling types.
To view stereotypes on the Activity Diagrams, click Tools > Options, select the
Diagram tab, and click Label, Decoration and label, Decoration only, or Icon in the
Stereotype box. Label displays the stereotype name in angle brackets (for example,
<<stereotype>>). Decoration displays a graphic marker such as highlighting an
icon or tool. Icon displays the graphical representation, if any.
Documentation
Describes model elements or relationships. The description can include information
such as the constraints, purpose, and essential behavior of the element.
Event
Specifies the names of all the events for transitions associated with the selected
synchronization.
An event causes a state transition. You do not have to uniquely label events because
one event can cause a transition to many different states, activities, synchronizations,
or decisions.
End
Specifies the target state or activity for transitions.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Transitions
A state transition indicates that an object in the source state will perform certain
specified actions and enter the destination state when a specified event occurs, or
when certain conditions are satisfied. A state transition is a relationship between two
states, two activities, between an activity and a state, a self-transition, a
synchronization, or a decision.
You can show one or more state transitions from a state as long as each transition is
unique. Transitions originating from a state cannot have the same event, unless there
are conditions on the event.
A state transition is a line with an arrowhead pointing toward the destination state or
activity.
You should label each state transition with the name of at least one event that causes
the state transition. You do not have to use unique labels for state transitions because
the same event can cause a transition to many different states or activities.
Only one event is allowed per transition, and one action per event.
Transitions 283
You can add events, conditions, and actions by using the Transition Specification
dialog.
Note: Transitions do not appear on the Model View tab in the browser.
Event
Specifies the event that causes the state transition. You do not have to uniquely label
events because one event can cause a transition to many different states or activities.
An event label is one of the following:
■
Symbolic name
■
Class name
■ Name of an operation
It is possible for a state transition to have no associated event.
Arguments
Specifies any optional arguments associated with the transition. One or more
arguments may accompany an event.
Stereotype
Specifies a keyword that further defines the classification of the model element. A
stereotype represents the subclassification of a model element. Some stereotypes are
already predefined, but you can also define your own to specify new modeling types.
Documentation
Describes model elements or relationships. The description can include information
such as the constraints, purpose, and essential behavior of the element.
Guard Condition
Conditional state transitions are triggered only when the conditional expression
evaluates to true.
Action
Shows the action that invokes a method, or starts and stops an activity on an Activity
Diagram. An action shows what occurs upon entering or exiting the state. Actions can
be messages to other objects, particularly when an Activity Diagram refers to an
active class (one that drives other objects).
Send event
Shows the send event for the selected transition. Event triggers can occur whenever
an action has occurred. An event can contain a symbolic name, class name, or name of
an operation. Event triggers are parsed into three components: Send Event, Send
Arguments, and Send Target.
Send arguments
Specifies any arguments for a send event. One or more arguments can accompany a
send event.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Swimlanes
Swimlanes are partitions on an Activity Diagram. Swimlanes are helpful when
modeling because they can represent organizational units or roles within a model.
Swimlanes are very similar to an object because they provide a way to tell who is
performing a certain role.
You can add states and activities within swimlanes to determine which unit is
responsible for carrying out the specific activity.
As you drag a swimlane onto an Activity Diagram, it becomes a swimlane view.
Swimlanes appear as small icons in the browser, while swimlane views appear
between vertical lines with a title that you can relocate and rename.
Creating Swimlanes
You will want to create a swimlane to add partitions to your Activity Diagrams.
To create a swimlane:
1 Create an Activity Diagram.
2 Click the Swimlane icon from the Activity Diagram Toolbox.
3 Click the pointer anywhere on the Activity Diagram to place the swimlane.
Deleting a Swimlane
You can delete a swimlane from an Activity Diagram, or from the model. Deleting a
swimlane from an Activity Diagram only deletes it from the diagram; the swimlane
remains on the Model View tab in the browser. Performing a hard delete removes the
swimlane from the entire model.
Note: The model elements residing within a swimlane are not deleted from the model
or removed from the diagram when you delete a swimlane.
Swimlanes 287
To delete a swimlane entirely from a model:
1 On an Activity Diagram, select the header of the swimlane.
2 Press CTRL + D.
To delete a swimlane only from the Activity Diagram (not the entire model):
1 Select a swimlane from an Activity Diagram by clicking on the swimlane header.
2 Press Delete or click Edit > Delete.
Moving a Swimlane
You can easily change the order of the swimlanes on an Activity Diagram. When
moving a swimlane, all the model elements within that swimlane, such as an Activity,
State, or Decision, move to the new location.
Note: When moving a swimlane, all diagram elements, excluding synchronizations,
are moved with the swimlane.
Name
Specifies the name of the currently selected swimlane.
Class
Specifies the name of the class the current swimlane is assigned. By default, the class
is unspecified.
Owner
Specifies the model elements that owns the selected Swimlane.
Documentation
Describes model elements or relationships. The description can include information
such as roles, keys, constraints, purpose, and essential behavior of the element.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Objects
An object has state, behavior, and identity. The structure and behavior of similar
objects are defined in their common class. Each object in an Activity Diagram
indicates some instance of a class. An object that is not named is referred to as a class
instance.
If you use the same name for several object icons appearing in the same Activity
Diagram, they are assumed to represent the same object; otherwise, each object icon
represents a distinct object. Object icons appearing in different diagrams denote
different objects, even when their names are identical.
The Object icon is similar to a Class icon, except that the name is underlined:
If you have multiple objects that are instances of the same class, you can modify the
object icon by setting the Multiple Instances option on the General tab in the Object
Specification dialog.
Concurrency
An object's concurrency is defined by the concurrency of its class. You can display
concurrency by right-clicking on an object and clicking Show Concurrency. The
adornment appears at the bottom of the Object icon.
Persistence
You can explicitly set the persistence of an object in the Object Specification dialog.
You can display this value as an adornment by right-clicking on an Object and
clicking Show Persistence. If you display both concurrency and persistence, the
object's persistence appears after the concurrency.
Object State
Most objects can appear in an infinite number of states. When you associate a new
state with an object, a new state appears in the browser along with the object. You may
specify more details of the object’s state in the State Specification dialog.
Object Flow
An object flow on an Activity Diagram represents the relationship between an activity
and the object that creates it (as an output) or uses it (as an input).
In Rational Rose RealTime, object flows appear as dashed arrows rather than solid
arrows to distinguish them from a typical transition. Object flows look identical to
dependencies that appear on other diagram types.
In the object flow sample, notice that the CD Player object appears on the diagram
more than once. However, each object appears in a different state: Playing, Paused,
and Stopped. Each activity changes the state of the CD Player when you push the
various buttons or perform the appropriate activity. For example, when the activity
Push Pause Button occurs, the state of the CD Player changes from [Playing] to
[Paused]. In most cases, the same object may be (and usually is) the output of one
activity, and the input of one or more subsequent activities.
To create an object:
1 Open an Activity Diagram.
2 Click Tools > Create > Object.
3 Click on the Activity Diagram to place an object.
Adding the Object, Object Flow, and Lock Selection Tools to the Toolsbar
By default, the Toolbar for Activity diagrams does not include the Object, Object
Flow, and Lock Selections Tools. You can easily add these tools by customizing the
Toolbar.
Name
Specifies the name of the parent class for the class instance. The name must identify a
class defined in the model.
Class
Specifies the name of the class that this object belongs. The default class for a newly
created object is (Unspecified).
If you delete a class from the model after you associated it with one or more objects,
the class name is enclosed in parentheses. If you re-create the class or create a new
class with the same name, the object becomes an instance of the new class.
State
Specifies the name for the object’s state. The default state for a newly created object is
(Unspecified).
Stereotype
Specifies the name for an object stereotype.
A stereotype represents the subclassification of a model element. Some stereotypes are
already predefined, but you can also define your own to specify new modeling types.
Documentation
Specifies any information regarding the selected object, such as its purpose and any
possible constraints.
Persistence
Specifies the lifetime for the object’s instances.
Persistence defines the lifetime of the instances of a class. A persistent element is
expected to have a life span beyond that of the program, or one that is shared with
other threads of control or other processes. Use this field to identify the persistence for
elements of this class:
■
Persistent - The state of the element exceeds the lifetime of the enclosing element.
■
Static - The state of the element is fixed.
■ Transient - The state and lifetime of the element are identical.
The persistence of an element must be compatible with the persistence you specified
for its corresponding class. If a class persistence is set to Persistent, the object
persistence is either persistent, static, or transient. If a class persistence is set to
Transient, the object persistence is either static or transient.
Multiple instances
Specifies that this object represents multiple instances of the same class. After you
select this option, the icon for an object on the Activity Diagram changes from one
object to three staggered objects.
Name
Displays a list of Object Flows coming in to the selected Object.
Name
Displays a list of Object Flows going out of the selected Object.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
Name
Specifies the name of the currently selected Object Flow.
Class
Specifies the name of the class that this Object Flow belongs.
Stereotype
Specifies a keyword that further defines the classification of the Object Flow.
A stereotype represents the subclassification of a model element. Some stereotypes are
already predefined but you can also define your own to specify new modeling types.
To view stereotypes on the Activity Diagrams, click Tools > Options, select the
Diagram tab, and click Label, Decoration and label, Decoration only, or Icon in the
Stereotype box. Label displays the stereotype name in angle brackets (for example,
<<stereotype>>). Decoration displays a graphic marker such as highlighting an
icon or tool. Icon displays the graphical representation, if any.
Documentation
Describes information, such as purpose and essential behavior, for the Object Flow.
Filename
Displays a list of referenced files. You can insert and delete references to files or URLs
by linking external files to model elements for documentation purposes.
Path
Specifies the location of the file or URL.
299
From the Browser
Editing a Diagram
Adding Instances
The instances or roles in the Sequence diagram should generally be drawn from the
instances or roles in the collaboration diagram. Collaboration and Sequence diagrams
can show interactions among object instances or among roles. In most cases, they are
more useful demonstrating interactions among roles, because a role demonstrates a
part played in the scenario, which could be played by more than one instance.
Sequence diagrams are not automatically populated with instances. The instances
must be added, either by dragging classes from the model browser or by using the
instance tool from the toolbox.
Instances added using the instance tool are unspecified by default, which means that
the tool does not know what actual design element the instance corresponds to. You
can specify a role or create a new one using the drop-down model box that appears
when you create a new instance. The Sequence diagram is not a complete specification
until all instances are mapped to actual design elements. Use the Path field on the
interaction instance specification dialog to specify which design instance the sequence
instance maps to.
A Sequence diagram created under a protocol is pre-populated with two instances:
base and conjugate. These instances cannot be removed and other instances cannot be
added.
Messages
Messages are created between instances or between instances and the Environment on
the diagram to show interaction. Messages can represent: asynchronous sends,
synchronous sends, function calls, instantiations, destructions, FOC (Focus of
Control) blocks, local states, local actions, and coregions.
You can use Copy and Paste commands on the following messages:
■
Synchronous Send Message
■
Asynchronous Send Message
■ Call Messages
■
Local Actions
■
Local States
You cannot use Copy and Paste commands on the following elements:
■
Focus of Control Blocks (FOCs)
■
Return Messages
■ Reply Messages
■
Coregions
■
Create message
■ Destroy/Terminate Messages
You can copy and paste multiple messages at the same time, and those copied
messages will preserve attributes of the original message when pasted.
Automatic Scrolling
If pasted elements appear outside of the visible area, the Sequence diagram scrolls so
that visible area for the pasted element is centered.
Known Limitations
Pasting messages on an Interaction Instance that has limited space between the
next-to-last message and the instance’s terminate/destroy message may created
pasted message overlapping either the next-to-last message or the terminate/destroy
message. You must manually adjust the placement of pasted messages.
You cannot copy model elements from a Sequence diagram if that diagram was
created from a trace with Don’t save with the model selected.
Reorienting Messages
You can reorient messages to make semantic changes in the diagram, for example, to
change the sender or receiver for a message.
Using the sender or receiver handles, you can change the sender or receiver. Using the
Re-order handle (Middle handle), you can change the order of this message on the
sender and receiver.
Moving Messages
You can move messages in a Sequence diagram to create more or less space between
them. Message movement is restricted to avoid accidentally altering the semantics of
the diagram. When moving a message, do not drag it using one of the handles.
Selector Tool
Select objects for moving, resizing, and so forth.
Zoom Tool
Zooms in on a portion of the diagram. Click on the Zoom tool and then click on the
area of the diagram to zoom in on.
Text Tool
Adds text anywhere in the diagram.
Note Tool
Annotates the diagram with textual notes. This is useful for marking up the diagram
with explanations, review comments, and so forth. You can drag and drop a diagram
or external document from the browser onto a note. Notice that the name of the
diagram or external document is underlined. If you double-click on the note, the
diagram or external document is opened. You can undo and redo this command.
Call Message
Adds a message between two instances. Call messages are like function calls, so the
sender is blocked waiting for a return.
Add FOC
Adds an FOC (Focus of Control) block to the selected message. Select the tool and
click on the send or call message you want to add an FOC to.
Note: If the selected message can have a reply or return (that is, a synchronous send
or call), it is automatically generated.
Coregion Tool
Indicates a set of events/messages whose ordering is undefined. That is, although the
messages appear in a particular order (as indicated by their vertical placement on the
instance line), the actual run-time ordering may vary.
General Tab
Name
Specifies the name of this instance. Instances are unnamed by default. The name is
displayed as part of the instance label on the diagram.
Path
Identifies the role path for an instance in a collaboration. The drop-down menu allows
you to choose from the available roles in the immediate collaboration associated with
the Sequence diagram.
Stereotype
Specifies the (optional) stereotype of this instance.
Documentation
Use the Documentation field to describe this instance.
Files Tab
The Files tab allows for linking external files.
Interaction Specification
The Interaction Specification is used to describe interactions on a Sequence diagram.
It has two tabs: General and Files
General Tab
Name
Specifies the name of the interaction.
Stereotype
Specifies the (optional) stereotype of this instance.
Documentation
Describes this interaction.
Files Tab
The Files tab allows for linking external files.
General Tab
Name
A name for the local action, which is displayed on the Sequence diagram.
Stereotype
Specifies a stereotype for the local action.
Detail Tab
Sender
Non-editable field with the name of the instance where the local action is defined.
Receiver
Not applicable to a local action.
Time
Capture the time of the action.
Effect
A textual description of the effect of the local action.
General Tab
Name
A name for the local state. The name is displayed on the Sequence diagram.
Detail Tab
Sender
Non-editable field with the name of the instance where the local state is defined.
Receiver
Not applicable for the local state
Time
Capture the time of the state change.
Message Specification
There are several different kinds of messages, but all have similar controls in the
Message Specification dialog.
The Message Specification dialog contains the following tabs: General, Detail, Port
Detail (only for Send messages), and Files.
General Tab
Name
A name for the message. The name is displayed on the Sequence diagram.
Stereotype
Specify a stereotype for the message.
Documentation
Specify documentation for this element.
Detail Tab
Sender
Non-editable field with the name of the instance where the message originated.
Time
Capture the time that the message was sent.
Data
A textual description of the message data.
From Port
The name of the port on the sender capsule.
Note: If the From Port box contains a port, the corresponding label becomes a hot link
to the Specification dialog for that port.
To Port
The name of the port on the receiver capsule.
Note: If the To Port box contains a port, the corresponding label becomes a hot link to
the Specification dialog for that port.
Delivered
Capture the time the message was delivered to the receiver.
Priority
The priority at which the message is sent. (Applies only to an Asynchronous Send
Message.)
Note: After you select <<Create a new Port>>, the <<Create a new Protocol>> list
appears. To cancel, click ESC.
In the From port box, the <<Create a new Port>> item appears in the list only when
the sender is a capsule.
In the To port box, the <<Create a new Port>> item appears in the list only when the
receiver is a capsule.
Focus of Control
Focus of Control (FOC) is an advanced notational technique that enhances Sequence
diagrams. This technique shows the period of time during which an object is
performing an action, either directly or through an underlying procedure.
FOC is portrayed through narrow rectangles that adorn lifelines (the vertical lines
descending from each object). The length of a FOC indicates the amount of time it
takes for a message to be performed. When you move a message vertically, each
dependent message moves vertically as well. Also, you can reorient a message
vertically off the source FOC to make it detached and independent.
Activators
Messages that originate from an FOC are said to have been activated by the message
that started that FOC.
To color a FOC:
1 Select the FOC you want to color.
2 Click Diagram Object Properties from the Edit menu and then click Fill Color.
3 Click on the color you want to make the selected FOC.
4 Click OK.
Note: The up and down arrow keys move the selection to the next selectable element
on the current lifeline (the vertical lines descending from each object).
You can identify the current lifeline by the selection marks on the lifeline (Figure 84).
If none of the lifelines in the sequence diagram have selection marks, the initial
navigation was not successful.
Once you select a current lifeline, you can make another lifeline current using the left
and right arrow keys to move horizontally to the nearest lifeline. When following a
message, such as moving to the right from the left end of a message between adjacent
lifelines, the current lifeline will change, and the selected message remains selected. If
the nearest lifeline in the appropriate direction is selected, the message on that lifeline
nearest the intersection point will be selected.
After you select a current lifeline, you can make another lifeline current using the left
and right arrow keys to move horizontally to the nearest lifeline. When following a
message, such as moving to the right from the left end of a message between adjacent
lifelines, the current lifeline will change, and the selected message remains selected. If
the nearest lifeline in the appropriate direction is selected, the message on that lifeline
nearest the intersection point will be selected.
By default, when you first select a message and attempt to navigate from it, the
current lifeline is set to the left end of the message (regardless of the message
orientation). Press CTRL and an arrow key to select the right end. When you establish
the current lifeline, pressing CTRL while using the arrow key toggles the current
lifeline from one end of the message to the other.
The environment in a sequence diagram has two visual lifelines at the left and right
borders of the diagram (see Figure 85). However, these border lifelines are modeled
by one interaction instance and each represent a single timeline.
Note: If you set the left or right border as the current lifeline, selecting the up or down
arrow selects the next element in the integrated view. This may result in the view
moving from the left border to the right border, or vice versa. This type of navigation
sequence illustrates the actual timeline of events for the environment.
Owned by model
Indicates whether the unit is owned by this collaboration, or whether it is owned by
another model and shared into this model. When selected, it indicates that this
collaboration is owned by another model.
Filename
Specifies the fully-qualified file name for the collaboration.
Version
Indicates the version information as defined by your configuration management
application.
RRTEI
The RRTEI allows the new attributes for Interactions and Collaborations to be
manipulated through the methods exposed by ControllableElement. To automate the
process of making sequence diagrams controllable units for existing models, you can
use, and modify, the Control Interaction scripts in the following location:
$ROSERT_HOME/Scripts/ControlInteractions
We recommend that you make a copy of these scripts before modifying them.
ControlInteractions_AddSequenceDiagrams.ebs
This is the second of three scripts used to make Sequence Diagrams controllable. This
script searches the model for Collaborations that are checked out and are a child of a
package. For each Collaboration, its contained Sequence Diagrams that are not
controlled are made controllable, and may be added to source control, if required.
9 Click OK.
If one or more Collaborations need to be controlled, you are prompted for
permission to check out the parent package for the Collaboration.
You must check out the parent package for the Collaboration because the
definition of an uncontrolled collaboration is part of the parent package. This
definition must be removed from the parent package and put into its own
controllable unit.
10 Click Yes to permit the checkout of the required packages.
11 In the Checkout dialog, select the packages to check out. If you did not allow
permission to check out the packages, the affected collaborations are ignored.
After the checkout completes, the uncontrolled collaborations are made
controllable.
13 Click OK.
Next, the script attempts to check out those collaborations that require changes.
The CheckOut dialog opens.
14 Select the collaborations to check out.
15 If the script detects that there are collaborations under source control that do not
have a child directory which is also under source control, it will prompt you to add
child directories to source control. Click Yes to open the Add To Source Control
dialog to select the directories to add to source control.
$ROSERT_HOME/Scripts/ControlInteractions
19 Select ControlInteractions_AddSequenceDiagrams.ebs.
$ROSERT_HOME/Scripts/ControlInteractions
26 Select the ControlInteractions_CheckIn.ebs script.
Creating a Class
Classes can be created in either the Logical View or the Use Case View in the Model
View Tab in the browser.
To create a class:
1 Right-click on the Logical View package in the Model View Tab in the browser (or
on the Use Case View package).
2 Select New >Class from the menu.
A new class is created with a default name of 'NewClass1'.
3 Type over the name to change it.
333
Creating New Attributes
Alternatively:
1 Open the Class Specification.
2 Select the Attributes tab.
3 Right-click and select Insert from the popup menu.
You can reorder attributes in the Specification dialog using drag-and-drop. You can
undo and redo this action.
Alternatively:
1 Open the Class Specification.
2 Select the Operations tab.
3 Right-click and select Insert from the popup menu.
4 Double-click on the new operation and use the Operation Specification Dialog to
specify the operation details.
Class Specification
Use the Class Specification dialog to edit the properties of a class. The dialog provides
access to all member attributes and operations as well.
Browse Button
Clicking Browse has the following options:
■
Select in Browser - Highlights the selected element in the browser.
■ Open Diagram - Opens the diagram associated with the object.
■
Browse Parent - Opens the specification for the parent of the selected element.
■
Browse Selection - Opens the specification for the currently selected element.
■
Show Usage - Displays a list of all diagrams in which the currently selected
element is the supplier, or in the case of a collaboration diagram, a list which
shows the usage of a message.
■ Find References - Finds all references of the item in the model by searching all
fields - excluding Documentation - and searching all objects - excluding Diagrams,
Component Instances, devices, Instances, Interactions, Messages, Packages,
Probes, and Processors. The results appear in the Find tab in the Output window.
Name
The name of the class.
Parent
The parent the class belongs to (its package, or class in the case of a nested class) is
displayed in this static field.
Type
The Type choices for the selected model element are:
■
Class
■ Parameterized class
■
Instantiated class
■
Utility class
■
Parameterized class utility
■
Instantiated class utility
■
Metaclass
Stereotype
A stereotype represents the subclassification of an element. It represents a class within
the UML metamodel itself, that is, a type of modeling element. Some stereotypes are
already predefined, but you can also define your own to add new kinds of modeling
types.
Stereotypes can be shown in the browser and on diagrams. The name of the
stereotype may appear in angle brackets <<>>, depending on the settings found in
either the Diagram or Browser tabs of the Options dialog box located under the Tools
menu. Refer to the Stereotype chapter for more information on stereotypes.
To show stereotypes on the diagrams, click Options from the shortcut menu and click
Stereotype Name or Stereotype Icon. Stereotype Name displays the name in angle
brackets (that is, <<stereotype>>). Stereotype Icon displays the graphical
representation.
Visibility
The Visibility field specifies how a class and its elements are viewed outside of the
defined package
Select: To Indicate:
Public The element is visible outside of the enclosing package and you
can import it to other portions of your model. Operations are
accessible to all clients.
Private The element is accessible only to its friends or to the class itself.
The Visibility field can be set only in the specification. No special annotation is related
to access control properties.
To change the visibility type for the class, click on the appropriate option in the
visibility field. You can display the implementation visibility in the component
compartment. You can display visibility in an icon through the shortcut menu.
Documentation
Specifies documentation on this element.
Multiplicity
The Multiplicity field specifies the number of expected instances of the class. In the
case of relationships, this field indicates the number of links between each instance of
the client class and the instance of the supplier. See Cardinality Options for more
information.
Persistence
Defines the lifetime of the instances of a class. A persistent element is expected to have
a life span beyond that of the program or one that is shared with other threads of
control or other processes.
The persistence of an element must be compatible with the persistence that you
specified for its class. If a class persistence is set to Persistent, then the object
persistence is either persistent, static or transient. If a class persistence is set to
Transient, then the object persistence is either static or transient.
You can set the persistence only through the specification.
To set the persistence, click on the applicable option in the Persistence field. You can
display the persistence in the diagram by selecting Show Persistence from the popup
menu.
Concurrency
Denotes the semantics in the presence of multiple threads of control. The Concurrency
field shows the concurrency for the elements of a class. The concurrency of an
operation should be consistent with its class.
Type Description:
■
Sequential (default) - The semantics of the class are guaranteed only in the
presence of a single thread of control. Only one thread of control can be executing
in the method at any one time.
■ Guarded - The semantics of the class are guaranteed in the presence of multiple
threads of control. A guarded class requires collaboration among client threads to
achieve mutual exclusion.
■
Active - The class has its own thread of control.
■ Synchronous - The semantics of the class are guaranteed in the presence of
multiple threads of control; mutual exclusion is supplied by the class.
To change the concurrency, click on an applicable option button in the Concurrency
box. You can display the concurrency in the class diagram by selecting Show
Concurrency from the popup menu.
Formal Arguments
In the Parameterized Class Specification or Parameterized Class Utility
Specification, the formal, generic parameters declared by the class or class utility are
listed.
In the Instantiated Class Specification or Instantiated Class Utility Specification,
the actual arguments that match the generic parameters of the class being instantiated
are listed.
You can add, update, or delete parameters only through the Class Specification. This
field applies only to parameterized classes, parameterized class utilities, instantiated
classes, and instantiated class utilities.
To define the parameters for a class, position the pointer within the Parameters box
and click Insert from the shortcut menu or press the insert key.
Parameters are displayed on class diagrams.
Show Inherited
Click this option to see operations inherited from other classes. If an operation is
inherited, a blue arrow prefixes the Operation type symbol, .
If this option is not selected, you can view only operations associated with the
selected class.
Note: Rational Rose RealTime allows you to directly modify any operation shown in
the Operations list by displaying the Operations Specification dialog. Use caution
when modifying base class operations because any changes may have implications on
other elements in your model which reference, or are subclassed from, the base class.
Components List
The components list displays a list of components to which this class has been
assigned. Components can be inserted, deleted, and moved up and down in the list.
Each component has a corresponding Component Specification for editing the
component attributes.
A check-box provides filtering control over which components are displayed:
Show all components displays the list of all components in the model.
Right-clicking on a component open the Component shortcut menu.
Relations List
The relations list displays relations between the class and other model classes as
specified in class diagrams. The relations list simply displays the relationships
involving this class that appear on class diagrams in the model.
Each relation has a corresponding Association Specification for editing the relation
attributes.
A check-box provides filtering control over which relations are displayed:
Show Inherited shows any relations inherited from a superclass protocol.
The first column contains the icon that corresponds to the diagram’s type. The Title
column contains the title for the diagram. You can modify the name of the title.
To add a new diagram, use the shortcut menu and select the desired Insert option.
Specification Content
The Attribute Specification dialog has of the following tabs: General, Detail, Files,
and other language-specific tabs.
Browse Button
Clicking Browse has the following options:
■
Select in Browser - Highlights the selected element in the browser.
■
Open Diagram - Opens the diagram associated with the object.
■
Browse Parent - Opens the specification for the parent of the selected element.
■ Browse Selection - Opens the specification for the currently selected element.
■ Show Usage - Displays a list of all diagrams in which the currently selected
element is the supplier, or in the case of a collaboration diagram, a list which
shows the usage of a message.
General Tab
Name
A name for the attribute. This name will be the name for the generated attribute.
Stereotype
A stereotype value.
Class
The class the attribute belongs to is displayed in this non-editable field.
Visibility
■
Public - The attribute is visible to any other classes.
■ Protected - The attribute is visible only to subclasses and friend classes.
■
Private - The attribute is not visible to any other classes, except designated friend
classes.
■
Implementation - The attribute is never visible to other classes.
Scope
■
Class - Ahere is a single instance of the attribute for all instances of the class (for
example a static member in C++ terminology).
■
Instance - Each instance of the class will have a separate attribute instance.
Type
Attribute types can either be classes or language-specific types. When the attribute is a
data value, the type is defined as a language-specific type. You can enter the type in
the Type field of the Class Attribute Specification. Rational Rose RealTime displays
the type beside the attribute name in the class icon and updates the information in the
model.
Note: If the Type box contains a class, the corresponding label becomes a hot link to
the Specification dialog for that class.
Initial Value
You can assign an initial value to your class attribute through this box. You can
specify multi-line expressions for initial data.
Changeability
■
Changeable - The attribute can be modified.
■
Frozen - The attribute cannot be modified.
■
Add-only - The attribute can only be updated in an additive way. This is not
enforceable in most programming languages.
Derived
The Derived check box indicates whether the element was computed or implemented
directly.
To define a element as derived, select the Derived check box. The element name is
adorned by a "/" in front of the name.
If the derived box is checked, no code is generated for the attribute.
Browse Button
Clicking Browse has the following options:
■
Select in Browser - Highlights the selected element in the browser.
■
Open Diagram - Opens the diagram associated with the object.
■ Browse Parent - Opens the specification for the parent of the selected element.
■
Browse Selection - Opens the specification for the currently selected element.
■
Show Usage - Displays a list of all diagrams in which the currently selected
element is the supplier, or in the case of a collaboration diagram, a list which
shows the usage of a message.
■
Find References - Finds all references of the item in the model by searching all
fields - excluding Documentation - and searching all objects - excluding Diagrams,
Component Instances, devices, Instances, Interactions, Messages, Packages,
Probes, and Processors. The results appear in the Find tab in the Output window.
General Tab
Name
The name of the operation. The named operation will be generated as a member of the
containing class.
Stereotype
Specifies a stereotype for the operation.
Class
A non-editable field that displays the class to which the operation belongs.
Options
■
Polymorphic - Indicates that the operation should be inherited by all subclasses.
■ Query - Indicates that the operation is read-only and does not modify the object's
state.
■
Abstract - Indicates that the operation is an abstract definition that should be
overridden by specific implementations in subclasses.
Scope
■
Instance - Indicates that the operation operates on individual class instances,
usually because its calculations are based on the object state, or because it modifies
the object state.
■
Class - Indicates that the operation operates the same way regardless of the state of
any individual object in the class.
Detail Tab
Return Type
For operations that are functions, set this field to identify the class or type of the
function's result. If show classes is set, the list box displays all the classes in the
package. If Show classes is not set, only the predefined set of return class types is
displayed.
If you enter a class name and it does not exist in your model, the application does not
create one.
Note: If the Return Type box contains a class, the corresponding label becomes a hot
link to the Specification dialog for that class.
Code
A code editor allowing you to enter the detailed implementation code for the
operation.
Validation Tab
Protocol
This field lists a set of operations that a client can perform on an object and the legal
orderings in which they might be invoked. The protocol of an operation has no
semantic impact.
Exceptions
This field contains a list of the exceptions that can be raised by the operation. Enter the
name of one or more classes identifying the exception.
Size
This field identifies the relative or absolute amount of storage consumed by the
invocation of the operation.
Time
This field contains a statement about the relative or absolute time required to
complete an operation. Use this field to budget time for the operation.
Concurrency
This field denotes the semantics in the presence of multiple threads of control. The
Concurrency field shows the concurrency for the elements of a class. The concurrency
of an operation should be consistent with its class.
Table 1 Concurrency Field Options
Type Description
Sequential The semantics of the operation are guaranteed only in the presence
(default) of a single thread of control. Only one thread of control can be
executing in the method at any one time.
You can set the concurrency of a class only through the Class Specification. To change
the concurrency, click on an applicable option in the Concurrency box. You can
display the concurrency in the class diagram by clicking Show Concurrency from the
context menu.
Preconditions
Invariants that are assumed by the operation (the entry behavior of an operation) are
listed.
Semantics
The action of the operation is shown in this area.
Postcondition
Invariants that are satisfied by the operation (the exit behavior of an operation) are
listed in this area.
Interaction Diagram
Select an interaction diagram from the list box that illustrates the appropriate
semantics. Selecting <New> brings up the New Interaction Diagram dialog, in which
you can specify the diagram type and title.
Name
Displays the name of the parameter.
Owner
Displays the owner of the parameter, that is, the operation to which the parameter
belongs.
Type
Specified the type for this parameter.
Note: If the Type box contains a class, the corresponding label becomes a hot link to
the Specification dialog for that class.
Documentation
Describes any details about the use of this parameter.
Files Tab
The Files tab provides a list of referenced files. You can link external files to model
elements for documentation purposes.
You can Undo and Redo any changes using the Edit menu.
State Diagram
The state diagram captures the high-level behavior of the capsule.
Structure Diagram
The structure diagram captures the interface and internal structure of the capsule in
terms of its contained capsules and ports.
Capsule Specification
The capsule specification is used to edit the properties of a capsule.
The capsule specification dialog contains the following tabs:
■ Capsule Specification - General Tab
■
Capsule Specification - Operations Tab
■
Capsule Specification - Attributes Tab
■
Capsule Specification - Capsule Roles Tab
■
Capsule Specification - Ports Tab
■ Capsule Specification - Connectors Tab
■ Capsule Specification - Relations Tab
■
Capsule Specification - Components Tab
■
Capsule Specification - Files Tab
Name
The name of the capsule class. The capsule class name may be referenced in the
detailed code of other capsule classes. One reason for this is for a container capsule to
instantiate an optional capsule role (see the Frame service incarnate function).
Stereotype
A stereotype represents the subclassification of an element. It represents a class within
the UML metamodel itself, that is, a type of modeling element. Some stereotypes are
already predefined, but you can also define your own to add new kinds of modeling
types.
Stereotypes can be shown in the browser and on diagrams. The name of the
stereotype may appear in angle brackets <<>>, depending on the settings found in
either the Diagram or Browser tabs of the Options dialog located under the Tools
menu. Refer to the Stereotype chapter for more information on stereotypes.
To show stereotypes on the diagrams, click Options from the shortcut menu and click
Stereotype Name or Stereotype Icon. Stereotype Name displays the name in angle
brackets (that is, <<stereotype>>). The Stereotype Icon displays the graphical
representation.
Documentation
Specifies documentation for this element.
Show Inherited
Set this option to display operations inherited from other classes. If an operation is
inherited, a blue arrow prefixes the Operation type symbol, .
If this option is not selected, you can view only operations associated with the
selected class.
Note: Rational Rose RealTime allows you to directly modify any operation shown in
the operations list by displaying the Operations Specification dialog. Use caution
when modifying base class operations because any changes may have implications on
other elements in your model which reference, or are subclassed from, the base class.
Show Inherited
Set this option to diaplay attributes inherited from other capsules. If there is no check
mark in this field, you can view only attributes associated with the selected capsule.
Note: Rose RealTime allows you to directly modify any attribute shown in the
attributes list by displaying the Attribute Specification dialog. You should be careful
when modifying base class attributes for it may have implications on other elements
in your model which reference or are subclassed from the base class.
Relations List
The relations list displays relations between the class and other model classes as
specified in class diagrams. The relations list displays the relationships involving this
class that appear on class diagrams in the model.
Each relation has a corresponding Association Specification for editing the relation
attributes.
A check-box provides filtering control over which relations are displayed:
Show Inherited shows any relations inherited from a superclass protocol.
Components List
The components list displays a list of components to which this class has been
assigned (a red check mark on the icon). Components can be inserted, deleted, and
moved up and down in the list. Each component has a corresponding Component
Specification for editing the component attributes.
A check-box provides filtering control over which components are displayed:
Show all components displays all the components in the model.
Right-clicking on a component opens the Components context menu.
Protocol Specification
The protocol specification provides control over the definition of a protocol class. The
dialog includes the following tabs:
■
Protocol Specification - General Tab
■
Protocol Specification - Signals Tab
■
Protocol Specification - Relations Tab
■
Protocol Specification - Components Tab
■
Protocol Specification - Files Tab
Browse Button
Clicking Browse displays the following options:
■
Select in Browser - Highlights the selected element in the browser.
■
Open Diagram - Opens the diagram associated with the object.
■
Browse Parent - Opens the specification for the parent of the selected element.
■
Browse Selection - Opens the specification for the currently selected element.
■ Show Usage - Displays a list of all diagrams in which the currently selected
element is the supplier, or in the case of a collaboration diagram, a list which
shows the usage of a message.
■ Find References - Finds all references of the item in the model by searching all
fields - excluding Documentation - and searching all objects - excluding Diagrams,
Component Instances, devices, Instances, Interactions, Messages, Packages,
Probes, and Processors. The results appear in the Find tab in the Output window.
361
Protocol Specification - General Tab
Name
The name of the Protocol Class.
Language
Select the implementation language for the class from the available languages. The
analysis selection indicates that no code will be generated for the class.
Stereotype
A stereotype represents the subclassification of an element. It represents a class within
the UML metamodel itself, that is, a type of modeling element. Some stereotypes are
already predefined, but you can also define your own to add new kinds of modeling
types.
Stereotypes can be shown in the browser and on diagrams. The name of the
stereotype may appear in angle brackets <<>>, depending on the settings found in
either the Diagram or Browser tabs of the Options dialog located under the Tools
menu. Refer to the Stereotype chapter for more information on stereotypes.
To show stereotypes on the diagrams, click Options from the shortcut menu and click
Stereotype Name or Stereotype Icon. Stereotype Name displays the name in angle
brackets (that is, <<stereotype>>). Stereotype Icon displays the graphical
representation.
Documentation
Specifies documentation for this element.
Copying Signals
To copy a signal from one Specification sheet to another, drag and drop it. From the
Edit menu of the main window, you can select Undo and Redo.
Relations List
The relations list displays relations between the protocol class and other model classes
as specified in class diagrams. Relations can be inserted, deleted, and moved up and
down in the list. Each relation has a corresponding Association Specification for
editing the relation attributes.
A check-box provides filtering control over which relations are displayed:
Show Inherited shows any relations inherited from a superclass protocol.
Right-clicking on a relation opens the Relation context menu.
Components List
The components list displays a list of components to which this class has been
assigned (a red check mark on the icon). Components can be inserted, deleted, and
moved up and down in the list. Each component has a corresponding Component
Specification for editing the component attributes.
Signal Specification
The dialog shows information about a signal in a protocol class. The signal
specification is opened from the Protocol Specification - Signals Tab.
Browse Button
Clicking Browse displays the following options:
■
Select in Browser - Highlights the selected element in the browser.
■ Open Diagram - Opens the diagram associated with the object.
■ Browse Parent - Opens the specification for the parent of the selected element.
■
Browse Selection - Opens the specification for the currently selected element.
Name
Specifies a name for the signal. The name is referenced in detail code when a capsule
sends a message through a port, and in the trigger event for transitions in the capsule
state diagram (through the Event Editor Dialog).
Data Class
Specifies the class of the data object that is expected as a payload of the message. The
data class field has a pull-down menu, which allows you to pick from the list of
available data classes and types in the model.
Note: If the Data Class box contains a class, the corresponding label becomes a hot
link to the Specification dialog for that class.
Introduction to Packages
Packages are organize model elements in larger models. Packages break up large
models containing hundreds or thousands of elements into smaller, more manageable
conceptual units. When properly designed, packages usually represent units of work
for an individual or team, and units of reusability. That is, a package represents a set
of highly related (highly cohesive) model elements. In most cases when looking to
reuse portions of a model across software projects, entire packages would be reused
rather than individual classes.
Packages also define the directory structure of a stored model. When a model is stored
as controlled units, a subdirectory is created for each package, such that the
representation of the model on disk mirrors the packaging hierarchy of the model in
the tool.
Creating a Package
Packages can be created in the Use Case View, the Logical View or the Component
View of the browser. Packages can contain other packages. In fact, the four main
views in the model browser are themselves packages.
367
To create a package:
1 Right-click on the package in the model browser where you want the new package
to be created.
2 Select New >Package from the menu.
A new package will be created with a default name of ‘NewPackage1'.
3 Type over the name to change it.
New model elements can be created within the package by clicking on the package
and selecting the right-mouse button to access the popup menu.
Existing model elements can be moved across packages. See Moving Model Elements
on page 372.
Package Specification
A Logical Package Specification enables you to display and modify the properties and
relationships of a logical package in the current model.
If you change a package's properties or relationships by editing its specification, the
application updates all class diagrams containing icons representing that logical
package. If you change a logical package's properties or relationships by editing a
diagram containing its icon, the application updates the logical package's
specification and any other diagrams containing its icon.
The package specification dialog provides control over the definition of a package.
The dialog includes the following tabs:
Name
The name of the package.
Parent
Displays the name of the parent package. If this is one of the top-level view packages,
the parent is the Model.
Stereotype
Displays the stereotype of the package. There are no pre-defined package stereotypes.
Global
The Global check-box indicates that all public classes in the logical package can be
used by any other logical package.
To switch the global adornment, click on the Global check-box. When you set the
global indicator, Rational Rose displays the word “global” in the lower left corner of
the logical package icon.
You can change the global adornment only through the specification.
Diagrams
This field lists the diagrams contained in the package. When you add a diagram to the
package, Rational Rose automatically updates this list.
The first column contains the diagram’s icon. The Title field is the title of the diagram
you entered (and can be modified).
To add a new diagram, use the shortcut menu and select the appropriate insert
diagram option.
Relations List
The relations list displays relations between the package and other model classes and
packages as specified in class diagrams. Relations can be inserted, deleted, and moved
up and down in the list. Each relation has a corresponding Association Specification
for editing the relation attributes.
A check-box provides filtering control over which relations are displayed.
Show Inherited
Shows any elements inherited from a superpackage.
Right-clicking on a relation brings up the Relation popup menu.
Components List
The components list displays a list of components that reference this package (red
checkmark). Components can be inserted, deleted, and moved up and down in the
list. Each component has a corresponding Component Specification for editing the
component attributes.
A check-box provides filtering control over which components are displayed:
Show all components displays the list of all components in the model.
Right-clicking on a component displays the Components context menu.
In the Model Elements tab, you can open the Specification dialog box for the selected
element, or delete selected items from the list.
To move multiple model elements using the Move Model Elements feature:
Note: The Move Model Elements feature can move capsules, protocols, classes, and
packages from the Logical View in the browser.
3 Find and select the package to move the selected model elements.
The Move Model Elements summary dialog shows the destination packages and
the model elements to move, as well as any model elements that cannot be moved.
5 To save the information on the Mode Model Elements summary dialog, click Save
Summary, and then specify a file name and location.
6 Click Yes.
The selected model elements move to the new location.
377
Figure 88 Component Diagram
Component
Components can be added to the diagram using either the component tool from the
toolbox, or by selecting a component from the Model View Tab in the browser and
dragging and dropping it on to the diagram. Components may have dependency or
aggregation relationships with other components.
The component details are specified through the Component Specification.
Dependency
A dependency indicates a client and supplier relationship. The client depends on the
supplier to provide certain services. Use this relationship to indicate that the
operations of the client invoke operations of the supplier.
Selector Tool
Selects objects for moving, resizing, and so forth.
Zoom Tool
Use to zoom in on a portion of the diagram. Click on the tool and then click on the
part of the diagram you want to zoom in on.
Text Tool
Adds text anywhere in the structure diagram.
Note Tool
Annotates the diagram with textual notes. This is useful for marking up the diagram
with explanations, review comments, and so forth. You can drag and drop a diagram
or external document from the browser onto a note. Notice that the name of the
diagram or external document is underlined. If you double-click on the note, the
diagram or external document is opened. You can undo and redo this command.
Package Tool
Adds a package to the diagram. The package is given a default name such as
'NewPackage1'.
Dependency tool
Indicates that a dependency is between packages or between components. A
dependency indicates that some element in one package depends on (uses) some
element in another package.
Component tool
Adds a component to the diagram. The component is given a default name such as
'NewComponent1'. See Building Basics on page 439 for more information on creating
and building components.
Processors
A processor is a hardware component capable of executing programs. You can further
define a processor by identifying its processes and specifying the type of process
scheduling it uses.
The Processor Specification Dialog dialog provides details on processor attributes.
Devices
A device is a hardware component with no computing power. Each device must have
a name. Device names can be generic, such as "modem" or "terminal."
The device specification dialog provides details on device attributes.
Connections
A connection represents some type of hardware coupling between two nodes. The
hardware coupling can be direct, such as an RS232 cable, or indirect, such as
satellite-to-ground communication. Connections are usually bi-directional.
The Connector Specification provides details on connection attributes.
Packages
Use to add a package to the diagram. The package is given a default name such as
'NewPackage1'.
Selector Tool
Selects objects for moving, resizing, and so forth.
Zoom Tool
Use to zoom in on a portion of the diagram. Click on the tool and then click on the
part of the diagram you want to zoom in on.
Text Tool
Adds text anywhere in the structure diagram.
Constraint Tool
Adds UML constraints to the diagram. A constraint can be anchored to a view
element by using the anchor tool. Currently, constraints do not have any semantic
meaning to the tool. There are RRTEI APIs to add or remove, and enumerate
constraints in a diagram.
Processor tool
Adds a processor node to the diagram. Click on the diagram to place a new processor
at the selected location.
Processors are given default names, such as 'processor1', when initially drawn. To
change the name, click on the device and hit the backspace key to delete the default
name, then type the new name.
Device Tool
Adds a device node to the diagram. Click on the diagram to place a new device at the
selected location. Devices are given default names, such as 'device1', when initially
drawn.
Connection Tool
Adds a connection between two nodes on the diagram. Click on the first node on the
diagram and drag the connection to the second node.
385
Code generation is different in Rational Rose and in Rational Rose RealTime. In
Rational Rose, the toolset generates skeleton code stored outside of the model. You
can edit the skeleton code with an editor to add additional code, or modify existing
code (such as operation bodies). In Rational Rose RealTime, you are not required to
edit the code after it has been generated. In some cases, code is stored in the model
itself (such as method bodies).
3 Review and set the appropriate options on all of the tabs in the Default Export
Option Set dialog to ensure the C++ Analyzer examines the appropriate code.
4 Click Update to update the current Export Option Set to reflect the modified
export options that you specified.
Note: The Update button is only available if you modify any export options since
the current option set was selected or updated.
5 Click Close.
7 In the Directory Structure area, browse to the directory that contains the source
code files for your model.
8 Add the source files to the Files In List area, or click Add All to add all of the files
at once.
9 Click OK.
Next, you want the C++ Analyzer to analyze the code you specified.
3 Click OK.
Files that contain errors have a plus sign (+) displayed next to them in the list of
selected files on the Project dialog.
4 In the Project dialog, double-click on a problem file to view the errors.
Note: The plus sign changes to a negative sign (-) to indicate the class information
has expanded.
Example
The following example shows the tags added to a member function of the class
Engine.
int Engine::start()
{
//## begin Engine::start%F0556897FEED.body preserve=yes
return 1;
//## end Engine::start%F0556897FEED.body
}
All tags will start with either begin or end. The rest of the tag depends on the type of
code being imported. In the above example, we are importing the body of a member
function so the next part of the tag is the name of the class followed by the name of the
function. Following that is the Rational Rose GUID for the corresponding operation,
followed by a unique tag (body in this case) that describes the type of information (the
body of a member function). The Rational Rose RealTime Code Import tool uses these
tags to determine where to place the code in the model.
Note: The Code Import tool examines the properties of classes and components to
determine the location of source code files. A component is examined only if its
stereotype is set to Package Body or Package Specification. If the files associated
with a component do not appear in the list of files to import, check the stereotype
for the component to ensure it is set to Package Body or Package Specification.
4 Click All >> to select all the files, or select only a subset of the files.
5 Click OK to import the code into the model.
For additonal information on the Convert Rose Component Wizard, see Using the
Convert Rose Component Wizard on page 397.
To convert a component:
1 Start Rational Rose RealTime.
2 Open a Rational Rose model.
3 Select a component, right-click, and then select Convert Rose Component.
Note: The Convert Rose Component menu command is available only when the
selected component contains Rational Rose data.
Exporting a File
You can export packages, classes, components, and use cases into .rtptl files.
Exporting these types of objects allows you to import these files into other models.
401
If a file is checked out to a user’s working area, it will be write-enabled. If the file is
not checked out, it will be read-only. To prevent multiple users from attempting to
make changes to the same file simultaneously, exclusive access is usually enforced.
This is accomplished by allowing only one user at a time to check out a file version. In
addition, some source control systems only allow the most recent version to be
checked out.
Example
Figure 93 shows the Structure diagram for a simple model.
In this example:
■
Capsule1 is a primary edit and it must be checked out to proceed with the edit.
■
Capsule2 is a secondary edit and it should be checked out but, if not, the edit can
proceed.
If Capsule2 is not checked out and the edited Capsule1 is checked in to source
control, users who open a model with those versions of Capsule1 and Capsule2 will
encounter a model validation error that corresponds to the deletion of the connector
in Capsule2.
If you delete port P1 from capsule class Capsule1, the port role P1 on capsule role
role1 in Capsule2 will also be deleted. This, in turn, would cause the connector to be
deleted in Capsule2.
The Browse for Folder dialog shows a subdirectory for each of the supported source
control tools. Depending on your configuration (UNIX or Windows), the directory
names corresponding to the source control systems directly supported by Rational
Rose RealTime will appear.
Note: Source control interface scripts are located in $ROSERT_HOME/bin/<host
platform>/cmscripts.
Optimizing Performance
The BatchSize and SupportsFileArgs options within the cm_getcaps script enable
you to optimize performance.
BatchSize
You can now the increase the BatchSize option that was previously set at 20 files. The
default is 30000, and the minimum is 1.
Note: If your CM scripts generate errors resulting in an inability to execute a
command in Rational Rose RealTime, decrease the BatchSize value.
SupportFileArgs
You can change the SupportsFileArgs option to False from the default setting of True.
When working with a large number of files, setting this option to False allows you to
bypass the command line by passing a temporary file which contains the
command-line arguments.
Alternatively, you can access source control operations using context menus in
browsers. When you select a controlled unit from the browser, the context menu
contains source control operations. To apply an operation to multiple units at the
same time, select all the desired units, and access the source control operation through
the context menu (Figure 97).
Synchronize
Performs the same status updating that the Refresh Status operation performs. The
Synchronize operation also determines if the file on disk has changed since the file
was loaded into the toolset. If the underlying file has changed, it is reloaded into the
toolset.
Note: For Rational ClearCase, if a dynamic view is used and the version of a file
available in the view changes, Synchronize detects the changes and reloads the file.
Synchronize is a safer operation than a Get because Synchronize will not lose any
checked out changes, while Get may replace your checked out changes with the most
recent version in the VOB.
Get
Interfaces with the active source control system and requests the latest version of the
files corresponding to the selected units. If a new version is retrieved, Rational Rose
RealTime reloads the file.
Note: For Rational ClearCase, Get does not retrieve a specific version of a file to a
view because the version being observed in a view can only be changed using the
config spec for that view. However, if a file is checked out, you can use Get to replace
the checked out file with a copy of a particular version of the file. If a file is not
checked out, performing a Get on that file is the same as performing a Synchronize
on the file.
Check Out
Prompts your source control system to lock the specified files so that you can modify
them, and then submit a new version using Check In. If the specified file is currently
checked out to another user, the check out operation fails. Check out retrieves the
latest version of the files being used.
Note: For Rational ClearCase, when working with a snapshot view, ClearCase marks
elements in the VOB as being checked out. When checking out an element, you are not
warned if a more recent version exists in VOB.
Add
Attempts to place the selected units under source control. After a unit is added to
source control, it can be versioned using Check Out and Check In. Unless a file must
be added to source control without submitting other changes at the same time, use
Submit All Changes rather than explicitly clicking Add.
Note: For Rational ClearCase, when adding files to source control, the ClearCase
integration assumes that the containing directory is under source control and is not
currently checked out. If the containing directory is already checked out, the Add
operation will fail.
Check In
Submits a checked out file to the repository so that a new version is stored. Unless a
file needs to be checked in without submitting other changes at the same time, use
Submit All Changes to submit changes to the repository.
Note: For Rational ClearCase, when checking in files, ClearCase copies the new
version to the VOB, as long as there is no successor version already in VOB. If there is
a successor, an error is returned from the scripts and will appear in the Log tab in the
Output window. To check in your changes, you must first merge the most recent
version from the VOB into your local copy.
To update your snapshot, click Tools > Source Control > Update Snapshot View. The
Update Snapshot View command helps you merge any changes. This is the preferred
method since your snapshot view will also get any new elements that appear in the
VOB.
Note: If you know that only one element has changed in the VOB, select that element
from the browser and use the context-menu Source Control > Get command to
retrieve the most recent version. Then perform the merge.
Apply Label
Instructs the source control system to apply a specified label to the selected units.
Directories may also be labelled with the option of working recursively on the
directory contents.
For Rational ClearCase, labelling a directory only applies the label to the directory
element itself. To apply the label to the files contained within a directory, use the
Recursive option.
Show Differences
Compares the local version of a unit with the latest version stored in the source
control repository.
For details on using the Merge Differencing tool, see the Rational Rose RealTime Model
Integrator documentation.
Note: Show Differences is only enabled when a single unit is selected.
Show History
Displays the version history of a unit based on the revisions of the file that are in the
source control repository.
Most source control systems support the retrieval of a specific version of a file. In
these systems, the Get button is enabled when a version is selected in the list.
To compare the local version of the unit with a specific version, right-click on the
version to compare, and click Show Differences.
For source control systems that support applying a label to arbitrary versions of
elements, the context menu will also include the Apply Label command.
Show History is only enabled when a single unit is selected.
By default, all new and checked out units are submitted. You can use the check boxes
on the left side of each unit to filter items from the list.
Parameters
Displays the Parameters dialog where you can specify parameters for the items.
Options for Obtaining Change Management Information When Loading a Model 417
Figure 101 shows the Model View tab when the units have CM information.
A new Status Bar indicator, UPD, identifies when a Background refresh occurs; for
Automatic and Manual modes, the Status bar indicator is blank.
Options for Obtaining Change Management Information When Loading a Model 419
To specify how to retrieve CM information when loading a model:
1 In the Model View tab in the browser, right-click on Model.
2 Click Open Specification.
Note: To enable the CM options, the Enable source control option must be selected.
By default, Automatic is selected. The CM option specified in this dialog is stored in
the workspace file and is used during the next model load.
CM Retrieval Options
In the Retrieve CM information on model load area, you have three options for
obtaining CM information when loading a model.
Automatic Mode
When selected, a non-interruptible CM refresh occurs immediately after the model
loads in the toolset.
Note: The toolset remains locked until the CM refresh activities complete.
Manual Mode
When selected, no CM information is obtained when loading a model. This means
that after the model loads, there is no additional delay because there is no CM
information being retrieved at this time. When using Manual mode, before
performing modifications to elements in the model, you must right-click on Model in
the Model View tab, then click Source Control > Refresh Status, or Source Control >
Refresh Status (with Child Units).
Limitations
Workspace files are not backward compatible because the new options are stored in
the workspace file.
If the Change Management operations are slow, using Background mode may reduce
the responsiveness of the Rational Rose RealTime application (during the
Background refresh). For this situation, we recommend that you use Automatic or
Manual mode.
A Background refresh may not obtain CM information for a unit if its parent was
edited before the CM information was obtained for the child unit. In this case, you
must manually refresh the CM information by right-clicking on Model in the Model
View tab, and then clicking Source Control > Refresh Status.
Options for Obtaining Change Management Information When Loading a Model 421
Checking Out Files When a Newer Version Exists
If you make a change that requires the Rational Rose RealTime toolset to
automatically check out one or more files, the toolset performs a "get" of the latest
version in your CM tool before checking out the file and then the toolset compares it
with the current version. If the version from your CM tool is newer, the toolset
prompts you with the following warning:
The units in source control are more recent than the current
version. If your checkout retrieves the latest version it
will need to be imported, and your current operation will be
lost.
Do you wish to continue with the checkout?
If you click No, the checkout is canceled and your changes are not applied.
If you click Yes, you may lose your changes. To ensure that you do not lose any
changes, set the Don’t get a local Copy option to True on the Parameters dialog by
clicking Parameters on the Checkout dialog.
Note: If you explicitly requested a checkou, this type of version checking is not
performed.
Get Dialog
A "get" interfaces with your active source control system and requests the latest
version of the files corresponding to the selected units. If a new version is retrieved,
Rational Rose RealTime reloads the file.
Use the Get dialog to request files from your CM tool (Figure 103). To access the Get
Entire Model dialog, click Tools > Source Control > Get Entire Model.
Note: The Get Entire Model option is not available for the current selection if it does
not contain units that are under source control.
Unit Name
Shows all the elements in the current model that you can update. Items that are not
under source control do not appear in this list.
File Name
Specifies the location of an element.
Filter
Specifies the level of refinement for getting elements from your source control tool.
Recursive
When selected, it indicates that the "get" command applies to current or specified
elements, and to any child controlled units.
Replace
Replaces your existing file with the version in source control.
Merge
Merges the version from source control with your current version.
Leave
Leaves this file alone and does nothing.
Cancel
Cancels the get operation. Any gets or merges done prior to clicking Cancel will
remain intact.
Note: For UNIX, the ClearCase Version Tree Browser diagram looks slightly
different.
■
From the command-line, type the following:
cleartool lsvtree -graphical <element_name>
■
Open ClearCase Explorer, and click Tools > Version Tree.
Assigning Names
Each unique model element must have a unique name, and each relationship can be
labeled with a word or phrase that denotes the semantics or purpose of the
relationship. You can type the name in the diagram or in the Name field in the
specification.
■ If you type the name in the diagram, your entry is displayed in the Name field.
■
If you type the name in the specification, the software displays the new name in
the element icon and updates the information in the model.
429
You can rename an element using one of the following methods:
■ Change its name in the diagram.
■
Change its name in the specification.
■
Change its name in the browser.
For more information about renaming, see the topic Renaming a Model Element.
Figure 107 shows the Alias tab for the Class Specification dialog box for the
CppHello class.
Figure 107 Class Specification Dialog Box for CppMain - Alias Tab
Figure 109 shows the context menu for a Class Diagram. To change the display to use
logical or physical names in your model, use the Show Logical Name if Defined
option from the Filter submenu.
Note: Since the filter option Show Logical Name if Defined is selected, you can edit
logical names on diagrams in the same way physical names are edited (that is, using
inline edit).
If the Show Logical Names id Defined option is selected, the title for the
corresponding diagram will have the string [Logical Names] appended to the end
of the name to provide a visual reminder that logical names (not physical names) are
being used.
The Filtering tab in the Options dialog box (see Figure 111) shows three Logical
Name options:
■
Class Diagram - Show logical names (1)
■
State Diagram - Show logical name
■
Structure and Collaboration diagrams - Show logical names (2)
437
Is Rational Rose RealTime a Compiler?
The answer is yes and no. Rational Rose RealTime compiles models into a high-level
language representation. It generates source code, or complete implementations, of
models while the generated source code is compiled and linked into machine
language using an external compiler and linker. The result is an executable that can be
run and observed via the Rose RealTime toolset.
Building
■
Building Basics - helps you build your first model
■ Creating a Component - using component aggregation
Executing
■
Execution Basics - Helps you run and observe your first model.
■ Loading and Running Component Instances on Embedded Targets - Target
loading, restarting, and resetting.
■
Overview of Observability Options - Watches, traces, sequence diagrams,
behavior breakpoints, logging output, source code break points.
■
Running from Outside the Toolset - Running a model without immediate
observation, attaching to a running model.
Building Basics
Before trying to build a model, it is important to understand the role of components
for modeling the physical aspects of a system. The physical elements of a model refer
specifically to source code and executables.
A component is always created with a default configuration for your host machine.
This includes a default compiler, compiler flags, linker, and so forth. In many cases
these settings are sufficient for building simple sets of classes and capsules that do not
require integration with external source files, or libraries.
This section leads you through the steps of building a simple model that does not
require integration with external files (everything is defined with the toolset). This
will help you understand the build workflow without getting into specialized
configuration options. After you understand the basic build workflow refer to the
Component Wizard for more information on configuring components with advanced
build setting.
To create a component:
1 Select the Component View folder, right-click and from the popup menu choose
New > Component.
A new component with the default settings for your platform is created.
2 Double-click on the default Component diagram, usually called Main, to open it.
3 Drag and drop the new component you just created onto the Component diagram.
4 Then drag and drop the top-level capsule onto the new component that was added
to the component diagram.
Note: You can also assign a capsule or class to a component by dragging and
dropping the capsule, class, or protocol from the model browser onto the
component in the model browser.
5 Open the components specification, switch to the References tab and set the
top-level capsule.
Alternatively, you can use the Component Wizard to help configure a component. To
run the Component Wizard, select Build > Component Wizard.
Starting a Build
When a component is built, there are actually quite a number of things that happen.
First the capsules referenced by the component are verified, then the model files are
written to disk, an external program is called to generate the source code from the
model files, the external compiler is invoked to compile, and lastly the linker is
invoked to create the final executable version of the component.
Each phase of the build process produces output that is used by the next phase, with
the final result being an executable.
Instead of directly building a component from the browser, you can build the active
component directly from the Build menu or by selecting one of the active component
toolbar buttons to verify, generate, or build the active component.
Generate Dialog
Use the Generate dialog to specify the build options for the selected component.
Build level
In this area, you can specify the build level for the selected component. The Build
level options are:
■
Generate - The capsules and classes referenced by the component are verified,
then the model files are written to disk.
■
Generate and compile - The capsules and classes referenced by the component are
verified, then the model files are written to disk, an external program is called to
generate the source code from the model files, the external compiler is invoked to
compile, and then the linker is invoked to create the final executable version of the
component.
Cause
Some compilers do not understand spaces in paths to files on Windows
configurations.
Resolution
If your compile does not understand spaces in the paths to files, you can:
■ Install Rational Rose RealTime to a location where the path does not contain
spaces.
■
Use the DOS name.
On Windows NT, to obtain the DOS name of a file, select the file in the Windows
NT explorer, right-click and select Properties. Now you have to use this DOS name
in your ROSERT_HOME environment variable.
After modifying the environment variable, modify your PathMap in the Rational
Rose RealTime toolset by clicking File > Edit PathMap, and then specify the same
name as indicated above.
Now, your model will build after you perform a full rebuild of your components.
■
Use the NT subst command
You can use the subst command to substitute a drive letter to the directory
containing spaces. You can then set you ROSERT_HOME environment variable to
this drive letter. For example:
subst K: "%ROSERT_HOME%"
set ROSERT_HOME=K:\
We recommend that you place the commands in a batch file and ensure this batch
file runs every time the workstation is started. Additionally, you must modify your
PathMap in the Rational Rose RealTime toolset by clicking File > Edit PathMap,
and rebuild the components.
■
Use Windows drive sharing
You can enable drive sharing on the directory that Rational Rose RealTime is
installed on, and map that directory to a drive letter. Additionally, you must
modify your PathMap in the Rational Rose RealTime toolset by clicking File > Edit
PathMap, and rebuild the components.
Selecting Elements
You can select one or more classes and capsules, or components from the Model View
tab in the browser, or directly from a Class diagram. However, all selected elements
must be of the same type and language. This means that your selection must contain
only classifiers (classes and capsules) or only components that are all the same
language (either all C, all C++, or all Java). Otherwise, the Browse Header (C and
C++) and Browse Body (C and C++), or the Browse Source (Java) options on the
context menu are not available.
Note: Before selecting a class, capsule, or component to view it’s generated code, you
must first build the component for that element. In addition, because you can assign a
capsule or class to one, or more components, different code can be generated for every
component for the selected model element.
If a model has an active component set that appears in the list of selected components,
it is automatically selected when Select Component dialog opens. For additional
information on setting a component as the active component for a model, see
Assigning an Active Component on page 440.
Note: For large models, you may encounter a delay before the Select Component
dialog appears.
Using an Editor
When viewing the code generated for selected model elements, you have two editor
options: using the Internal Editor or specifying an External Editor.
Internal Editor
Included with Rational Rose RealTime is an editor that you can use to open code
generated for classes, capsules, and components.
Note: If you do not specify an external editor, Rational Rose RealTime automatically
uses it’s internal editor. The Internal editor can open only one file at a time. If you
have multiple elements selected, only the header, body, or source file for the elements
selected first appears in the internal editor. We recommend that you specify an
external editor if you want to view the code generated for multiple files.
For information on using the shortcut keys in the internal editor, see Rational Rose
RealTime Keyboard Shortcut Summary on page 571.
External Editor
You can specify an external editor to view files containing generated code. Specifying
an external editor may provide you with additional capabilities, as well as allowing
the toolset to open multiple files at the same time.You can specify an external editor
by clicking Tools > Options, and selecting the Editor tab.
For information on specifying an external editor, see Editor Tab on page 559.
Build Menu
Build
Opens the Build dialog from which you can choose the Build Level.
Quick Build
Builds the component incrementally.
Clean
Removes all files from the output directory.
Code Sync
Invokes the mechanism to capture external changes made to the generated code back
into the model. For more information, see “Using Code Sync to Change Generated
Code” on page 531.
Stop Build
Stops the build (or the Code Sync) in progress.
Run
Loads the component instances specified in the Build Settings Dialog. The component
must be successfully built before it can run.
If the Attach Target observability flag was set on the Component Instance
Specification dialog, and a Target observability Port number filled in, then the
execution interface is displayed allowing you to control the execution of the model.
Start (F5)
Starts the execution of the component instances. If the component instances are in the
reset state, then execution begins with all fixed capsules being initialized (initial
transitions fired). If the component instances are in the stop state, then execution
resumes.
Stop (Shift+F5)
Stops the execution of the component instances at the current point of execution and
remembers the state of all capsules. Execution is stopped as soon as each currently
running transition is finished. The stop button does not halt execution in the middle
of a transition action.
Restart (Ctrl+Shift+F5)
Resets the component instances, resetting all fixed and destroying all dynamic
capsule instances. The running component instance is terminated and a new one is
run.
Load
Loads the components instances specified in the Build Settings dialog. The
component must be successfully built before it can run. The Load command spawns
an external process in which the model executable runs. You will likely see an external
command window appear.
The Attach Target observability flag must be set on the Component Instance
Specification dialog, and a Target Observability Port number filled in for the model to
be loaded within the tool.
The execution interface is displayed allowing you to control the execution of the
model. See Execution basics for more information on the execution tools.
Reload
Kills the existing model process and runs the model again. The execution interface
stays open.
Shutdown
Kills the existing model process and closes the execution interface.
Settings...
Displays the Build Settings Dialog. You must use this dialog to specify the active
component before you can build the component.
Active Component
Used to select an active component. The combo box contains all components in your
model.
Component Specification
A Component Specification displays and modifies the properties and relationships
of each component in the current model, and is used for all component kinds.
Specification Content
The Component Specification consists of the following tabs:
■
Component Specification - General Tab
■ Component Specification - References Tab
■ Component Specification - Relations Tab
■
Component Specification - Files Tab
Name
The component name is referenced during the build process.
Parent
Specifies the parent component package.
Environment
Specifies the run-time system and code generator used in the build.
Type
Specifies what is being built, for example, an executable or a library.
C++ Executable - Allows you to build a C++ executable based on a main program.
This type of component cannot contain capsules and has no dependencies on the
TargetRTS.
C Executable - Allows you to build a C executable based on a main program. This
type of component cannot contain capsules and has no dependencies on the
TargetRTS.
Stereotype
A component stereotype represents the subclassification of an element. The most
common type of components are already predefined as stereotypes, including Main
Program, Package Body, Package Specification, Subprogram Body, Subprogram
Specification, Task Body and Task Specification. You can also define and add your
own kinds of stereotypes.
Documentation
Provides a description about the selected component.
References List
The references list displays the list of packages (includes all elements in the package),
classes, capsules and protocols to be compiled with this component.
Relations List
The relations list displays aggregation relations between the component and other
components in component diagrams.
For a component, the C++ Generation tab for C++ (C Generation tab for C) contains
all of the fields for which you can generate documentation (see Figure 115).
Option Description
do not generate The default option is do not generate. Documentation is not generated
when this option is selected.
prefer in header When selected, the documentation appears with the generated source
for the model element in the header file. If the model element does not
appear in the header file but appears in the implementation file, then
the documentation is generated in the implementation file.
prefer in When selected, the documentation appears with the generated source
implementation for the model element in the implementation file. If the model element
does not appear in the implementation file but appears in the header
file, then the documentation is generated in the header file.
Comments are generated in the implementation file whenever
possible, and in the header file only if necessary.
only in header The code generator outputs documentation only if the source for the
affected model element appears in the header file.
only in The code generator outputs documentation only if the source for the
implementation affected model element appears in the implementation file.
Documentation is generated as a comment with its own RME tag (for general
documentation), and if code sync is enabled, the documentation is enclosed in USR
tags (see Figure 116). When Code sync is enabled, empty documentation fields
continue to be generated in the source file allowing you to add new comments
between the USR tags in the generated code. To ensure the unambiguous use of code
sync, each generated documentation field in the source files (header or
implementation) are generated only once in the source code.
Figure 117 shows the generated documentation with code sync enabled.
Note: When code sync is disabled, comments are generated in the source files without
USR tags (see Figure 122). Also, empty documentation fields are not generated.
Figure 119 shows the results after building the model (the code that is generated in the
header file for CppMain.h).
Figure 120 Class Specification Dialog Box for the Class CppMain
To see the documentation fields, select the desired component from the Model View
tab in the browser, right click and select Open Specification, then click the C++
Generation tab. At the bottom of this tab, select prefer in header for the Class
documentation box (see Figure 121). For this example, we will also select the
CodeSyncEnabled option.
Note: When the label for a box is bold, it means that this property is overridden.
After you build the model, if you open the header file (CppMain.h), the file is updated
to include the text in the Documentation box for all classes in the model.
Note: Some types of model elements have source code generated only in the header
file or only in the implementation file. For example, capsule role and port RME tags
appear only in the header file so the documentation cannot be generated in the
implementation file. Similarly, RME tags for states are generated only in the
implementation file.
Component Dependencies
You can break up the system you are building into multiple components. Model the
build dependencies using the component dependencies.
See the Guide to Team Development - Rational Rose RealTime and language-specific
guides for more information.
Unknown command, command not found, the name specified is not recognized
■
Is your compiler installed correctly?
■
Is your make program configured and installed correctly?
■
Are you linking with the correct Services Libraries?
■
Are the Rose RealTime environment variables set?
463
Missing Class Dependencies
Missing dependencies are a common source of compilation errors. You need to
identify which capsules and classes depend on other classes in your model. That way
when you compile a capsule or class, it will find the definition of the class you depend
upon. Also if that class's interface changes, the build process will automatically
rebuild all the capsules and classes that depend upon it.
To resolve these types of errors add the correct dependencies between classes using
the Build > Add Class Dependencies Wizard or by manually creating a dependency
relationship between classes.
You will likely see the following type of error message if you have not specified a
library or object files that should be linked into your model:
unresolved external symbol "int __cdecl print_this(void)"
fatal error XXXXXX: 1 unresolved externals
Compile Fails on Valid C++ Models with VC++ 5.0 or VC++ 6.0
The $INCLUDE and $LIB environment variables may not be properly set. Ensure that
your compiler binaries are on the path and that the $INCLUDE and $LIB environment
variables are set (for example, they could be set for the user who installed VC++, but
not set for another user). Set the environment variables. Refer to the VC++
documentation for further details.
Error loading Capsule ("could not spawn process")
If the executable (capsule1.exe) is stored on an NFS server then the NFS client must be
configured to have execute permission set.
Saving the Build Output to a File Directly from the Build Log Tab
You can automatically or manually capture all of the build output to a log file to
process the output later.
2 In the AutoSave Log dialog, specify a name for the log file and select a location.
3 Click OK.
4 Build your model.
Note: If you attempt to open the Build Log file, you may encounter a Sharing
Violation message. To view the contents of the Build Log output file, right-click in the
Build Log tab, click AutoSave, and then open the log file.
2 In the Save Log dialog, specify a name for the log file and select a location.
3 Click OK.
2 In the Import Build Output dialog, specify the name for the .log or .txt file
containing the build compilation results.
3 Click Open.
The Build Log tab now contains the results from a previous build.
Note: When importing the build log file (after saving the log file in Rational Rose
RealTime by clicking Save As from the context menu on the Build Log tab), only the
Build Log results are imported. No build errors are imported because clicking Save
As only saves the Build Log results. However, if you create a log file from the
command line, importing the results will populate the Build Log and the Build Errors
tab.
7 In the Import Build Output dialog, specify the name for the .log or .txt file
containing the build compilation results.
8 Click Open.
The Build Errors tab now contains the results captured from the command-line.
Note: When importing the build file (the output file created from the command-line),
if you specified redirection for both standard out and standard error, the compilation
results for both the Build Log and the Build Errors tabs are imported.
475
Execution Basics
After a component has been built successfully, you can run the resulting executable. If
you have Purify installed, you can run the executable with Purify, to customize error
detection for each component in your program. After the component has been built,
see Running a Component Instance with Purify on page 477. If you do not have Purify
installed, see Running a Component Instance without Purify on page 479.
Rational Rose RealTime provides an execution environment that can be used to
execute and observe component instances on a processor (a type of node).
While a component instance runs, you can control and observe its execution. This
functionality is very powerful: it allows a component instance to be observed at the
modeling language level, rather than at the source code level.
Tasks
1 Creating a component instance
2 Running a component instance with Purify
3 Running a component instance without Purify
4 Observing a running component instance
Tasks
1 Select the Deployment View folder, right-click and from the popup menu click
New > Processor.
2 A new processor with the default settings for your platform is created.
3 Double-click on the Deployment diagram to open it.
4 Drag and drop the processor onto the Deployment diagram.
5 Then drag and drop a component from the Component View model browser on to
the processor that was just added to the Deployment diagram.
Note: You can also create a component instance by dragging and dropping a
component from the model browser onto a processor in the model browser or to
the Processor Specification - Detail tab.
Tasks
If you have configured an active component, then once the build is complete, you can
use the execute icon from the toolbar (press F5), or select Build > Run with Purify
from the main menu to automatically run all the component instances selected in the
Build Settings dialog.
You can also run any component instance by selecting the component instance from
the model browser, right-clicking and selecting Run with Purify from the popup
menu.
After you select Run with Purify, you will be prompted to select Yes if you haven’t
got a build. After you answer the prompt, it may take a minute or so before the toolset
finishes running the executable, especially for a large model.
Tasks
If you have configured an active component, then once the build is complete you can
use the execute icon from the toolbar (press F5), or select Build > Run from the main
menu to automatically run all the component instances selected in the Build Settings
dialog.
2 Bring control back to the toolset by clicking on any part of the toolset. You will
notice a new tab called RTS has been added on you model browser. The browser
contained in this new window is called the RTS Browser. It is used to control the
execution of a running component instance. You can run and control multiple
component instances from within Rational Rose RealTime, for each running
instance there is a separate RTS Browser tab.
3 Click on the new tab to show the RTS Browser.
4 The execution control buttons are at the top of the RTS Browser. Press the Start
button to start the execution of the loaded component instance. Everything printed
from your model to stdout and stderr will be shown in the console window that
appeared when the component instance was loaded.
5 When you are finished running the component instance, press the shutdown
button. The component instance is killed and control is returned to Rational Rose
RealTime.
Note: You can also control the execution of a component instance by using the entries
in the Build section of the main menu, or in the popup menu of a component instance.
Tasks
Observe a running capsule instance by opening monitors and message traces:
1 Once you have followed the steps to run your component instance, change to the
RTS browser tab and press the Start button.
2 Expand the top-level capsule folder and select a leaf capsule instance. Non-leaf
capsules instances represent the class of the instances.
3 Right-click on a capsule instance, and from the popup menu select Open State
Monitor.
A monitor window appears, and you should be able to see the state machine of
this capsule instance. The current state is highlighted in black. In addition the last
transition fired is drawn in black.
4 Select the Probes tool from the monitor toolbox. Place a probe onto a state by
moving the probe cursor over the state then clicking the left mouse button to apply
the probe to the state.
Select the probe that you have just applied to a state, and from the popup menu
choose Open Trace Window.
5 The opened trace window shows all messages that occur in this state. Follow
similar steps for adding probes to ports, and junction points.
6 Notice that any new probe that is added to a monitor is also added to the Probes
folder in the RTS Browser. You can perform common operations on probes by
using the popup menu from the Probes folder.
Traces Use traces to see the messages that are being sent within
the system.
Injecting Messages Inject test messages into a model to unit test capsules.
Probe Break Points Use probe breakpoints to stop a running model when a
specified event is received.
Source Code Debugging Debug detail code problems using a source code
debugger.
Load
Loads or downloads a component instance to a target platform. The load does not
start the execution of the loaded component instance. Use Run once it is loaded. This
is only used with target platforms that require loading of modules before they are run.
For platforms that do not require loading of modules, this menu item is disabled.
Unload
Use only with target platforms that require loading of modules before they are run.
For platforms that do not require loading of modules, this menu item is disabled.
Run
Starts the execution of the component instance. If observability is configured to attach
at start-up the RTS browser appears. When observability is attached at start-up the
component instance is paused, or does not start processing messages, until the start
button is pressed on the RTS Browser.
Shutdown
Kills the running component instance, closing the RTS Browser if necessary.
Restart
Kills the running component instance and runs another instance. If the instance is
running on an target board, the component is reloaded before a new instance is run.
Reload
Used only with target platforms that require loading of modules before they are run.
For platforms that do not require loading of modules, this menu item is disabled. This
unloads then loads the component without resetting the target board.
Detach Target
Detaches observability, meaning that the toolset no longer communicates with the
running component instance. This menu item can only be used with Attach Target.
Attach Console
Attaches a console window to the executing target model to interact with the
command line model debugger, and so forth.
View BreakPoints
Displays a list of all current breakpoints for the selected component.
RTS Browser
The RTS Browser appears as an additional tab on the model browser. It provides an
execution interface for controlling the running instance. There is always one RTS
Browser for each component instance that is running with observability. The browser
is composed of three main parts: an execution control and information pane, a capsule
instance browser, and a probes browser.
Probes Folder
The Probes folder lists the current probes. Right-click on a probe in the list to gain
quick access to the common operations performed with probes.
Note: The defailt name for probes includes the capsule instance name and its
corresponding replication index.
Animation
To allow observation of state and structure, monitors provide visual clues during
execution. The structure monitor shows changes in the dynamic structure by showing
optional capsule roles that have not been created with the traditional shading. Once
they are created, they are shown as fixed capsule roles. Also, current cardinalities of
capsule instances are shown. In order to find specific instances of a replicated capsule
role as shown in the structure monitor, you can use the cardinality browser tool.
In the State, or state diagram monitor, the current state is highlighted. In addition, if
the state diagram shows hierarchical states, the last active state remains highlighted.
When a transition is taken, the state monitor highlights the transition.
Opening a Monitor
Select a capsule instance from the RTS browser, and from its popup menu, select
either Open Structure Monitor or Open State Monitor.
Probes
From within a monitor, you can place probes on ports, junction points, and states by
using the Probes tool.
Monitors 489
Navigating to Model Elements from Debug Monitors
A very powerful feature of Rational Rose RealTime is the ability to observe a running
component instance at the model level. In Rational Rose RealTime, you can see the
triggered transitions, the active states in the state diagram monitors, and you can
watch the dynamic structure animate in the Structure Monitor.
The context menus for the State Monitor (see Figure 125) and Structure Monitor
include two new options: Open State Diagram and Open Structure Diagram. These
options facilitate navigation to the design elements during a debug session.
Trace Windows
Trace windows are used to log messages sent or triggering events in a running
system. Trace windows show lists of messages, including local state, incarnate and
destroy, and import and deport messages. Each row in the list corresponds to one
message. Rows can be divided into multiple columns, where each column is used to
display different details regarding the message in that row.
Port trace Shows messages Time, direction (I/O), Creating a probe on a port,
coming in or out of priority, signal, data then selecting Open Trace
a specific port from the Probes popup
menu.
Deleting Messages
Any message can be deleted from the trace by right-clicking on a message in the list
then selecting Delete from the popup menu.
Trace Configuration
You can configure the information displayed in the trace window by right-clicking in
the trace window and selecting Configure... from the popup menu. The Trace
Configuration dialog appears.
You can enable Relay Port Tracing by selecting the Relay Port Tracing check box. If
this check box is selected, all messages between capsule instances, including instances
being received through relay ports, appear in a trace. For messages relayed to
sub-capsules within a capsule, the trace shows through which ports these messages
were passed.
To observe the message passing, convert the trace to a sequence diagram.
Probes
Probes are used to monitor messages passing through ports and events that trigger
transitions in a running capsule instance. They are attached to states, junction points,
or ports by using the probe tool, which is available when viewing a state diagram or
structure monitor of a capsule instance.
Probes can be placed on instances that have not yet been created, for example, even
before the component instance is running. Probes are associated with component
instances and are stored with them, such that they do not have to be redefined each
time the component instance is run. A component instance’s probes are listed in the
RTS browser, inside the probes folder.
port probe ports, replicated ports Port probes allow tracing messages passing
through the port, or in the case of replicated
ports, messages passing through all
instances of the port. They also allow you to
inject messages to a port.
state probe junction points, states State probes placed on junction points allow
tracing of events that trigger the associated
transition. Probes on states trace all
messages that occur in that state. State
probes do not allow message injection. They
can, however, be used as state break points
to stop the execution of the system when a
particular probe has been reached.
Use the Probe Specification dialog to configure a probe. You can also use a probe’s
context menu to quickly open the probe Trace window, the Inject window, and
activate or deactivate a probe.
Probes 493
Placing Probes on Replicated Ports
If a port is replicated you can place a probe on all instances of the ports by closing the
'*' from the port instance browser. This results in a probe that monitors and injects on
all instances of the port. You can also place a probe on a particular instance of a port
by selecting a particular instance number from the port Instance browser, then placing
the probe on the port.
Inject Window
On a port probe specification sheet the Probe Specification—Detail tab allows you to
define messages and send them in or out of the port on which the probe is attached.
Inject messages also appear under the owning port probe in both state and structure
monitor diagram browsers. The inject message context menu lets you inject, modify,
or delete an inject message. Double-clicking the inject message injects the message.
Threshold Field
An integer value used to specify the maximum number of events displayed in the
trace window before discarding on a first-in first-out basis. The default threshold
is 25.
Note: Messages are also buffered in the running component instance. The larger the
threshold, the more memory is allocated in the running component instance. This can
be set in the Probe specification threshold.
To add an attribute instance or variable to the watch window, open a state monitor
and drag-and-drop the attribute from the Attributes folder into the watch window.
You can also edit the value of a variable by selecting the Value field then entering
another value for the variable.
Rational Rose RealTime can help you resolve design errors. For example, problems
with state machine logic can be found with a state monitor and message sequencing
problems can be found with traces. However, when your model contains detail level
coding errors that cause exceptions, the best tool for resolving these problems is your
source level debugger. You can add source breakpoints from within a state monitor to
automatically launch a source code debugger to help you resolve detail level coding
errors.
3 Select the top or bottom arrow to select a particular instance. For ports you can
select the '*' entry in the instances list to select all port instances.
Note: As you change the cardinality you may notice the capsules border and shading
change to reflect the state of the instance you are viewing.
2 Load the source debugger and component instance by choosing Load from the
component instance right-click menu or the load button from the toolbar.
At this point the source debugger should be loaded and initialized. The
component instance has not run yet, hence the RTS Browser is not visible.
Note: Do not forget to configure the component to generate debugging
information when compiled. Refer to your compiler and linker documentation for
the specific flags that should be used to include debug info into an executable. If
the component instance is loaded into the source debugger without debug
symbols the source debugger will usually inform you of this.
3 Run the component instance (see Running a Component Instance with Purify on
page 477 or Running a Component Instance without Purify on page 479).
Setting Breakpoints
You can set breakpoints on a state machine or for operations for your C and C++
models. This means that, for example, for non-dynamic models such as C models,
there is support for source debugger integration at the state machine and operation
level, when there is no Target Observability (TO).
5 Click OK.
Note: You must create a debug build of your model, otherwise it will not contain
any debug information, and your breakpoints cannot be set and will be disabled.
For additional information, see Starting a Build on page 441.
6 Build the components for the selected processor.
For more information on building a component, see Starting a Build on page 441.
7 In the Deployment View, right-click on the same component instance and click
Load.
The debugger you selected opens your debugging application.
The browser for the Breakpoint Diagram dialog shows states similar to that of a
typical state monitor browser. However, instead of displaying the elements (such
as attributes, end ports, and probes), it shows all the capsules associated with the
component for the Component Instance opened in the initial state monitor.
Note: To open a Breakpoint Diagram dialog for a capsule that is not the top
capsule, right-click on that capsule on the BreakPoint Diagram dialog, then click
Open Breakpoint Diagram.
9 On the Breakpoint Diagram Toolbar, click the Breakpoint icon, .
11 To view all of the breakpoints you specified (those associated with the selected
component instance), in the Deployment View, right-click on the component
instance and click View Breakpoints.
Note: Unlike the Breakpoint Diagram dialog, the Breakpoints dialog is available
during TO.
The Location and Context for each breakpoint displays in the list.
Click Remove to delete the currently selected breakpoints.
In the Breakpoints dialog, you can right-click and select Show in diagram to
navigate to the breakpoint in either the Breakpoint Diagram dialog or the state
monitor, depending on whether TO is used.
The Breakpoint Specification dialog shows the file, line number, and function on
which the selected breakpoint is set.
Now, in your debugger, you can look at the breakpoints that you specified.
14 In the Deployment View in the Model View tab in the browser, right-click on the
component instance, and then click Run.
15 Maximize your debugging application to view information regarding the
breakpoints you set earlier.
16 When finished viewing the breakpoints in your debugger application, return to
Rational Rose RealTime, right-click on the component instance, and click Unload.
Customizing Rational Rose RealTime for Target Control and Observability 507
Running from Outside the Toolset
Binary files or executables built from Rational Rose RealTime do not necessarily have
to be run from within the toolset. In some cases it is necessary to run, or even
download to another machine (usually a RTOS), the executable manually. For
example, this is useful if you are using a target for which the target control scripts and
programs are not available.
Purify
You can run Purify from outside the toolset and import the Purify results into the
Rational Rose RealTime.
1 When using Purify outside the toolset, run the results.
2 Save the results as plain text.
3 Import the results into Rational Rose RealTime by going to the Purify pane and
selecting Import from the context menu.
If the purify output matches a line of code in the model, then the corresponding line of
code in Purify appears bold.
-obslisten
This parameter instruct syour component instance to listen at the specified TCP/IP
port for observability connections from the toolset. For example:
%myProgram -obslisten=67887 -URTS_DEBUG=go
quit
Quits the debugger automatically and allow the process to run freely.
continue
Allows you to start running the target and make TO connections at a later time. From
the command line, continue is similar to clicking Run in the Toolset; it starts the
execution while retaining control (unlike quit which gives up control). For example:
MyTopCapsule -obslisten=1234 -URTS_DEBUG=continue
Specification Contents
The Component Instance specification dialog contains the following tabs: General,
Detail, Purify (if installed) and Files.
Name
The name of the component instance.
Note: This is not the name of the actual executable that was created from the build.
Parameters
Text in this field represents command line arguments that are passed on the command
line when the component instance is loaded. The content of this field is passed as is.
Operation Mode
The operation mode specifies the target control configuration for the component
instance. The Basic option configures the component instance to use the target control
utilities to load and run the component instance. The Manual option instructs the
toolset not to attempt to load the component instance.
In addition, if you are setting source level breakpoint Probes, you will have to select
the debugger that will be loaded by the target control scripts for your platform. Basic
mode is implied when one of the debugger options is not selected.
1. The xxgdb integration works differently from the MSDEV and Tornado. Follow these steps:
1.Build the desired component with the appropriate debug options, for
example, -g.
2.In the component instance specification, select Debugger-xxgdb for Operation
Mode.
3.Start TO.
4.Open the desired State Monitors. You may need to “step” to get access to them.
5.Set breakpoints on the appropriate elements within the desired State Monitor.
8.Remember to continue in the debugger when you hit a breakpoint. The toolset
gets no indication that a breakpoint was hit.
9.If you remove breakpoints, they will not take effect until you restart the model
again.
Load/Run
■
Order - An integer value representing the relative order in which this component
instance is loaded, or run, in relation to other component instances listed and
selections in the Build Settings dialog. Lower numbers are run first.
■
Delay - An integer value representing the number of seconds to delay before the
component instance is loaded or run. This is useful when simultaneously running
multiple component instances specified in the Build Settings dialog. If you want to
Ensure that one component instance has time to start correctly before running the
other - for example, if they need to communicate - you can specify a run delay for
the second component.
Connection Delay
■
An integer value representing the maximum number of seconds Rational Rose
RealTime takes while attempting to collect process information. This allows Purify
time to instrument the executable as necessary. For a large module, you will need
to adjust the connection delay to be more than the default of 60 seconds. Then, the
toolset waits for the interval specified on the Connect delay option on the Detail
tab before attempting to connect to the target.
Specification Contents
The processor specification dialog contains the following tabs: General, Detail, Files.
Name
A name for the processor. The name appears on the deployment diagram, but the
name is not used for execution purposes. The actual target id is specified using the
address field on the Detail tab.
CPU
Name of the type of central processing unit for this processor element.
OS
Name of the operating system running on this processor.
Server
In some environments there is a server that handles loading and executing of a
component instance for the target RTOS. This is the name or the address of this server.
Load script
Path to the target control utility directory that contains the scripts and programs that
are responsible for loading and unloading processes on that processor. If this field
does not point to a valid script directory you will not be able to execute component
instances from within the toolset.
Component Instances
This is the list of component instances that will run on this processor. You can add a
component instance to this list by dragging and dropping a component instance from
the model browser to this list. Dropping a component instance on a processor results
in the creation of a process. You can also right click and select Insert. The Create
Component Instance dialog appears in which you can select a component to create an
instance from and give it a name. See the Processor specification dialog for process
details.
Browse
When you click the Browse button, the Select Directory dialog appears from which
you can locate the Target Scripts directories.
Using Windows CE
To allow control of component instances for the Windows CE platform, the target
control utilities are implemented as a set of external executables and scripts that are
invoked from the toolset to perform the various target control tasks.
These scripts and executables for target control are located in the following directory:
$Target_scripts = $ROSERT_HOME\bin\tc\win32\wince
12 Click OK.
1 In the Model View tab in the browser, select the processor from the Deployment
View folder.
2 Right-click and click Open Specification.
3 Click the Detail tab.
4 In the Operation mode box, select Debugger-Tornado or Debugger-Tornado2.
5 In the Server box, you must specify the name of server that will be the target
server.
6 Click OK.
12 Click OK.
13 In the Model View tab in the browser, select the component instance.
15 Right-click and click Run. If prompted to build the component instance, click Yes.
After the source debugger is loaded, it remains loaded until the Unload command for
the component instance is selected. This means that the source debugger can remain
open while the component instance runs and restarts multiple times.
On the target Windows CE device, it loads the TCKill agent for your specific target.
Now, you can set breakpoints and debug your model.
Note: For Windows CE, the EMVT debugger mode does not use the TCKill agent.
Unloading a Debugger
Device Specification
The Device specification dialog contains three tabs: the General tab, the Detail tab,
and the Files tab:
General Tab
Name
The name of the device.
Stereotype
A stereotype label for the device.
Documentation
Use this field to describe the device.
Characteristics
Use the Characteristics text field to specify a physical description of the hardware
component. For example, you can describe the kind and bandwidth of a connection,
the manufacturer, model, memory, and disks of a machine, or the kind and size of a
device. You can set this field only through the specification. This information is not
displayed in the deployment diagram.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
Connection Specification
The Connection specification contains three tabs: the General tab, the Detail tab, and
the Files tab.
General Tab
Name
The name of the connection.
Stereotype
A stereotype label for the connection.
Documentation
Use this field to describe the connection.
Characteristics
Use the Characteristics text field to specify a physical description of the hardware
component. For example, you can describe the kind and bandwidth of a connection,
the manufacturer, model, memory, and disks of a machine, or the kind and size of a
device. You can set this field only through the specification. This information is not
displayed in the deployment diagram.
Files Tab
A list of referenced files is provided here. The files list popup menu allows you to
insert and delete references to files or URLs.
You can link external files to model elements for documentation purposes.
Probe Specification
The Probe Specification dialog contains two tabs: General and Files.
Name
The name of the probe, which you can edit if you choose.
Activated
Enables the probe.
Halt
Halts the execution when this probe detects a message. Upon halting execution, the
appropriate Structure Monitor diagram opens and this probe will be selected.
Trace
Opens the Trace window.
Threshold
Sets the size of the message buffer on the target.
Message list
This tab contains the list of messages that can be injected into the port. The list shows
the direction (in/out), priority, signal name, and data of each message.
Examples
Basic types
If a signal has a basic type that is a data class
int -> int 5
char -> char'a'
Classes
Here are two examples of what should be entered into the Data area of an inject
message to inject data of the following types. Do not enclose the data in double
quotes. The string below each class diagram would be entered as is into the Data area
of the inject message.
TestData{result
1,test_identifier'A',node{connects{name'\0','\0','\0','\0','\0'
, hostid 0},{name'\0','\0','\0','\0','\0',hostid
0},{name'\0','\0','\0','\0','\0', hostid
0},{name'\0','\0','\0','\0','\0',hostid 0}}}
Note: To help determine the format of data types remember that the inject data format
will always be the same as you would see the data displayed in a trace window.
Injecting a Message
To inject a message that shows in the inject list, select the message and from the popup
menu choose Inject.
If an error occurs parsing the Data area of the inject message, an error will not be
returned to the toolset. The message will simply not get injected. The best method of
determining whether a message was injected successfully is to open a trace window
on the port into which the message is being injected. If the inject is successful you will
see the message in the trace.
Inject messages can also be injected, modified, or deleted in the State monitor browser.
They are child elements of port probes.
531
Intended Code Sync Usage
Limitations
Code Sync cannot be used to create, delete or rename model elements, or to otherwise
make structural changes to the model. Such changes must be made using the toolset.
After the generated code has been modified externally, the toolset should not be used
to run the externally-built executable until all code Sync changes have been
reconciled. For example, although state transitions could be observed and animated
by the toolset, the toolset will still show the old transition action code which may be
misleading during debugging.
After the generated code has been manually modified, Clearmake cannot provide
complete traceability back to model files, and Clearmake cannot provide wink-in. In
Clearmake terms, generated code that has been manually modified is no longer
considered a derived object, but rather a view-private file.
Context
The location within the model of the model element, where the changes were made by
the user.
Accepting Changes
To accept changes:
1 From the Code Sync Summary dialog, double-click each location you wish to
view. The old code block and new code block appears for the selected location.
You can right-click on a change to bring up its context within the toolset. Be sure to
return to the Code Sync Summary before modifying the model.
2 To reject changes that you do not wish to propagate into the model, deselect the
check box(es). These rejected changes may include debug information placed in
the Code Sync area while debugging within your IDE.
3 Ensure that you have not rejected any code that is required for the model. Click
OK to accept the selected changes.
Model files are checked out of version control as necessary once the changes are
accepted.
539
Generate Documentation Dialog
The Generate Documentation dialog shows options for creating documentation from
the model.
Report Title
Give the report a title.
Report Type
Select the type of document to generate from the following options:
■
Logical View Report - generates documentation only for elements in the logical
view.
■
Component View Report - generates documentation only for elements in the
component view
Report Options
■
Include Operations - includes all class operations in the document.
■
Include Attributes - includes all class attributes in the document.
■ Sort - specifies that the reports appear in alphabetical order
■ Public Operations and Attributes Only - includes only publicly visible class
operations and attributes in the document.
■
Include Documentation - includes user-specified documentation entered in
specification dialogs in the document.
Generate Selected
Generate documentation for only selected model elements.
Cancel
Cancel the operation.
Option A
1 Click on the diagram you want to put into your document and select Edit >Select
All.
2 Copy the diagram to the clipboard using Edit > Copy.
3 Position the cursor in the word document where you want the diagram to be
placed and select Edit > Paste.
Option B
1 Click on the diagram you want to put into your document and select Edit >Select
All.
2 Click File > Print.
3 Select Print to file.
4 Click OK.
5 Choose the directory in which you want to save the file.
6 Type a file name in the File name box.
7 Click Save.
8 Open Microsoft Word.
9 Select Insert > Picture > From File...
10 Select the file you saved in Step 6.
Note: You will not see the actual diagram in your Microsoft Word document; only a
postscript reference is displayed.
Creating a Link
After creating and saving your model, copy the contents of a diagram, either by CTRL
+ C or Edit > Copy.
Note: If the model is new, it must first be saved for this operation to work.
Inserting a Link
In an OLE container, for example a Microsoft Word document:
1 Select Edit > Paste Special.
2 Click the Picture option and Paste Link.
3 Click OK.
If you select just Paste you will get a meta file picture inserted into the container. This
meta file is not navigable and becomes native data in the container.
Navigating
To navigate from your OLE container (for example, your Microsoft Word document)
to the application, use the steps for opening OLE linked objects, typically, double-click
or Open from the Edit Object menu. The application opens the diagram independent
of the Load of Units setting.
Note: Moving your linked files may break the link. It does not, however, affect the
object in the container. If the link breaks, you can manually reestablish it from most
OLE containers with the Change Source option from the Links dialog.
Editing Diagrams
Unless the unit is read-only, you can edit your linked (source) diagram. When you
modify your diagram, the link is updated to reflect the new state. Depending on the
application containing the diagram, you may have to do a manual update to see your
changes. Refer to your application manual for details.
Stereotypes
This topic describes the following:
■
Creating a Custom Framework for Rose RealTime Models on page 543
■
Creating a New Stereotype for the Current Model on page 544
■
Creating a New Stereotype Configuration File on page 545
■
Creating a New Stereotype for all Rose RealTime Models on page 545
■
Creating Stereotypes for Classes on page 548
■
Adding Stereotypes to the Diagram Toolbox on page 548
■
Creating Stereotype Icons on page 548
■
Creating a Diagram Icon on page 549
■
Controlling the Display of Stereotypes on page 549
543
To create a custom framework:
1 If you do not have a model file that defines the contents of the framework, create a
framework model. You create the framework model in the same way as you would
create any other model in Rational Rose Realtime. See Building Basics on page 439.
2 Optionally, you may create the following files for the model:
❑ a documentation file (.TXT) that contains a description of the framework.
❑ an icon file (.ICO) that contains the icon to be used as a symbol for the new
framework in the Create New Model dialog.
3 Select File > New. The Create New Model dialog appears.
4 Select New Framework to enter the Framework wizard.
5 When prompted by the wizard, enter the following information:
❑
Framework Name - this name will appear as a label for your framework in the
Create New Model dialog.
❑
Model file - the name of your framework model file (.rtmdl)
❑
Documentation file (optional)
❑
Icon file, if created (optional)
6 Follow the prompts and click Finish to exit the wizard.
To create a new stereotype and make it available in all models in Rational Rose
RealTime:
1 Exit Rational Rose RealTime.
2 Optionally, create icons for the stereotype to use in diagrams, lists, and diagram
toolboxes. See Controlling the Display of Stereotypes on page 549.
Stereotypes 545
3 Open the default stereotype configuration file, DefaultStereotypes.ini in
%ROSERT_HOME%.
4 In the stereotype configuration file, add a line for the new stereotype in the section
called [Stereotype Items]. For example, to add the class stereotype Controller to
an existing configuration file, add a corresponding line as follows:
[Stereotype Items]
Class:Model
Class:View
Class:Control
5 Create a section for the new stereotype and give it the exact same name you
specified in Step 4. For example:
[Class:Control]
Item=Class
Stereotype=Control
6 If you created a diagram icon for the stereotype, specify the name of that file
(Metafile).
Note: You can use the ampersnad character, “&”, instead of the folder of the
stereotype configuration file. For example:
Metafile=&MyStereotypeIconscontroller.emf
7 To create a diagram toolbox button for this stereotype, specify the name of the file
where you created the corresponding small toolbox icon (SmallPaletteImages) and
the location of the icon in that file (SmallPaletteIndex). You can also specify the
name of the file where the corresponding large toolbox icon is defined
(MediumPaletteImages) and the location of the icon in that file
(MediumPaletteIndex). For example:
SmallPaletteImages=&\MyStereotypeIcons\small_palette_icons.bmp
SmallPaletteIndex=3
MediumPaletteImages=&\MyStereotypeIcons\medium_palette_icons.bmp
MediumPaletteIndex=3
8 To graphically display this stereotype in specification lists or in the browser,
specify the name of the file where you created its list icon (ListImages) and the
location of the icon in that file (ListIndex). For example:
ListImages=&\MyStereotypeIcons\list_icons.bmp
ListIndex=2
12 Start Rational Rose RealTime. View the Log tab in the Output window to ensure
that there are no problems loading your icons.
13 If you created a diagram toolbox icon for the new stereotype, and want to add it as
a button on a diagram toolbox, see Adding Stereotypes to the Diagram Toolbox on
page 548.
The new stereotype is now available in Rational Rose RealTime. For information on
how to control the display of the new stereotype in diagrams and in the browser, see
Controlling the Display of Stereotypes on page 549
For detailed samples on user-defined stereotypes, please refer to
http://www.rational.com/products/rosert/
Stereotypes 547
Creating Stereotypes for Classes
Stereotypes 549
4 To control the display of, for example, a class, a device, or a component, click
Stereotype Display and select the appropriate option from the displayed menu.
5 To control the display of operation and attribute stereotypes in the class
compartment, use the Show compartment stereotypes option.
To control how stereotypes that are added to diagrams hereafter are displayed:
1 Select Tools > Options > Diagram tab.
2 To control the display of relationship stereotypes, use the Show labels on relations
and associations option under Stereotype display.
3 To control the display of, for example, class, device, or component stereotypes, use
the None, Label, Decoration and Label, Label Only or Icon options under
Stereotype display.
4 To control the display of operation and attribute stereotypes in class
compartments, use the Show stereotypes option under Compartments.
Note: For user-defined stereotypes, the stereotype display may be controlled by the
settings in the stereotype configuration file where the stereotype is defined. Any such
settings override the settings on the Diagram tab of the Options dialog.
Toolset Options
This section describes the Options Dialog, Customizing the Diagram Toolbox, and the
Customize Toolbar Dialog.
Options Dialog
The Options dialog provides control over many general properties of the model.
The Options dialog contains the following tabs: General Tab, File Tab, Font/Color Tab,
Diagram Tab, Filtering Tab, Compartments Tab, Browser Tab, THIDC_AA1oolbars
Tab, Editor Tab, and Language/Environment Tab.
There are some fields which are common to many tabs on the Options dialog:
Type
Specifies a type, such as Class, Protocol, Role and Attribute. The list of types differs
depending on the tab selected.
Clone
Duplicates the selected type.
Remove
Deletes a select cloned type from the Set box.
General Tab
At Startup options
Reload last workspace
Automatically loads the last workspace (and corresponding model) that were in use
when the tool was last shut down.
Show splash screen
Toggles whether the splash screen at appears at startup. The default is set to true.
Show frameworks dialog
Sets the display of the Frameworks dialog on startup.
Emulate REI
When enabled, Rose RealTime emulates Rose 2000 from a COM server perspective at
startup. This lets you use Rose 2000 Add-Ins with Rose RealTime. Rose 2000 and Rose
RealTime are both REI servers. Which one is used to serve a request depends on the
specific launched/shutdown sequence of Rose 2000 and Rose RealTime instances that
occurred on the server system. Regardless of whether it emulates REI, Rose RealTime
always serves as an RRTEI server.
The option can be overridden by the following command line arguments:
■ -emulateREI: Emulates REI, regardless of the default specified in the option
dialog.
■
-noEmulateREI: Does not emulate REI, regardless of the default specified in the
option dialog.
Error Log
Log size
Sets the number of lines in the error log.
Log warnings
Enables warnings to be sent to the log. The default is set to true.
Log commands
Sends a description of executed commands to the log. The default is set to true.
Note: To reduce the amount of entries that appear in the log (meaning only warnings
are visible) ensure that this option is not set when running RQART.
Undo
Undo level
Sets the number of undo levels supported. A higher number consumes more memory.
Technical Support
Email address
Sets the email address to which error files are automatically sent if the tool crashes.
These error files contain only internal callstack information from the tool. They do not
contain any model-specific information.
Test button
Tests the given email address to ensure its validity.
File Tab
Save options
Use Temporary File
Font/Color Tab
Default font
Invokes the Font dialog, through which you can specify font characteristics.
Code font
Specify a default font for code boxes.
Line Color...
Changes the color of any lines used on diagrams.
Fill Color...
Changes the color of any element fills used on diagrams.
Background color...
Changes the background color for diagrams.
Display
Unresolved Adornments
Enables adornment of icons representing components not currently loaded in the
model. The unresolved view adornment is a small octagon containing the letter “M”
with a slash through it.
Collaboration Numbering
Enables the display of message sequence numbers on Collaboration diagrams.
Sequence Numbering
Enables the display of message sequence numbers on Sequence diagrams.
Focus Of Control
The DefaultViewFocusOfControl setting is an advanced notational technique that
enhances sequence diagrams. Focus of Control is portrayed through narrow
rectangles that adorn the vertical lines that descend from each object. You can also
change this setting (DefaultViewFocusOfControl) directly in the rose.ini file. The
DefaultViewFocusOfControl default setting is Yes.
Show message data
Shows the data associated with a message on the diagram.
Default line attributes...
Opens the Line Attributes dialog, which let you define line styles, routing, smoothing,
and intersecting links.
■ Line style - Lets you decide whether line styles are oblique or rectilinear. Note that
if you choose Rectilinear, Smoothing is grayed out.
■
Routing - Lets you decide whether routing is normal, closest distance, or avoids
obstructions. Note that if you choose Closest distance, Smoothing is grayed out.
■ Smoothing - Lets you choose how smooth lines are.
■ Intersecting links - Lets you choose whether to jump links and specify the type of
jump. As well, you can choose whether to reverse jump links.
Stereotype Display
Use the options to control the display of stereotypes in diagrams. The selection is
applied to new model elements (except relationships) that are added to diagrams
hereafter.
■ None - The stereotype is not indicated for new model elements.
■
Label - The stereotype name is displayed for new model elements. The stereotype
name appears inside angle brackets, << >>.
Grid
Grid Size
Specifies the grid pitch in pixels. The value that you enter in the Grid Size edit box is
saved to the GridSizeX and Y settings.
Snap to Grid
Indicates that new or moved icons will align with a grid whose pitch is specified by
the grid size.
UML Options
Aggregation whole to part
Controls which way an aggregation can be drawn. Aggregates can be drawn whole
(client) to part (supplier) or vice versa. The default is set to true.
Classifier name on roles
Lets you turn off the classifier name portion of a role label.
Protocol name on ports
Lets you turn off the classifier name portion on ports.
Target Observability
Animation timeout
Sets a delay for displaying animation of events (state changes) in the state monitor.
The delay value is in 1/100ths of a second, i.e., a value of 100 will delay event
animation for 1 second. This provides the ability to slow down the animation of a
model to make state changes more observable.
Filtering Tab
Class Diagram
Filters information on the class diagram.
State Diagram
Filters information on the state diagram.
Structure/Collaboration Diagrams
Filters information on Structure/Collaboration diagrams.
Compartments Tab
Class
Display/hide information in the compartments of a class on the class diagram.
Capsule
Display/hide information in the compartments of a class on the class diagram.
Protocol
Display/hide information in the compartments of a class on the class diagram.
Stereotypes
Show stereotype names
Enable or disable viewing of stereotype names of model elements in the browser.
To display only stereotype icons (if any), select the Hide Stereotype name if there is
an icon for it option.
To display both stereotype icons (if any) and stereotype names, clear the Hide
Stereotype name if there is an icon for it option.
Hide stereotype name if there is an icon for it
The StereotypeBitmapsOnly setting enables or disables stereotype icons, but not
stereotype names, of model elements in the browser. This setting can also be changed
in the rose.ini file.
Editor Tab
External editor
Specify an external editor to be launched when editing detailed code.
Note: If you use an external editor that requires a console terminal, you must specify
an application, such as xterm, that provides the terminal, followed by the editor
command itself.
Example on Solaris: /usr/openwin/bin/xterm -e /bin/vi
Example on HPUX: /usr/bin/X11/xterm -e /bin/vi
Language/Environment Tab
Default Language
Select the language from the available installed language add-ins. When a new class is
created, this selection determines which:
■
language property tab is displayed for classes
■ set of fundamental types is used for picklists
■ set of predefined stereotypes is used
When a new component is created, the language is set using this default.
If you do not have any language add-ins, the default language is set to Analysis,
which is equivalent to having no default language. If this is the case, analysis types
are shown in the picklists and no language property tabs are available.
To remove the overriding value from the item and once again inherit from the
attached model property set:
1 Select one or more model properties and click Default.
2 Click OK or Apply to commit the changes to the item.
General Shortcuts
Table 2 General desktop navigation
ALT or META + key Display the contents of a menu - in combination with the
underlined letter in the menu's name
ALT + ALT or Display the context menu for selected model element.
Shortcut Menu Key Note: On Unix, by default clicking the ALT key activates a context
menu, so pressing it once changes the focus to the application’s
main menu. Unix keyboards have two additional keys, a left and
right diamond, which are similar to the ALT key. The left diamond
works the same as the ALT key by making the main menu active. If
you use the right diamond, you must press it three times to change
the focus to the main menu.
565
Key Name(s) Description
ALT + LEFT Opens the previous specification in the Specification History list.
ALT + SHIFT + LEFT Opens the previous specification without closing the current
Specification dialog.
ALT + RIGHT Opens the next specification in the Specification History list.
ALT + SHIFT + RIGHT Opens the next specification without closing the current Specification
dialog.
CTRL + + Go Inside
CTRL + - Go Outside
CTRL + C Copy
CTRL + E Expand
CTRL + I Zoom in
CTRL + N Opens a new window for editing, or opens the Create New Model
dialog
CTRL + P Print
CTRL + O Open
CTRL + S Save
CTRL + T Browse state diagram (Creates a diagram if one does not currently
exist)
CTRL + SHIFT + T Browse structure diagram (Creates a diagram if one does not
currently exist)
CTRL + V Paste
CTRL + X Cut
CTRL + Y Redo
CTRL + Z Undo
DEL Delete
ESC Cancel
F1 Context-sensitive help
F2 Refresh
F4 Browse parent
F8 Edit inline
F12 Options
Editing Shortcuts
Table 4 Scripting Shortcuts
LEFT ARROW Moves the insertion point left by one character position.
RIGHT ARROW Moves the insertion point right by one character position.
CTRL + PAGE DOWN Scrolls the insertion point right by one window.
CTRL + LEFT ARROW Moves the insertion point to the start of the next word to the left.
CTRL + RIGHT Moves the insertion point to the start of the next word to the right.
ARROW
HOME Places the insertion point before the first character in the line.
END Places the insertion point after the last character in the line.
CTRL + HOME Places the insertion point before the first character in the script.
CTRL + END Places the insertion point after the last character in the script.
Debugging Shortcuts
Table 5 Debugging Shortcuts
CTRL + C Copy
CTRL + F Find
CTRL + G Go to line
CTRL + H Replace
CTRL + P Print
CTRL + R Replace
CTRL + V Paste
CTRL + X Cut
CTRL + Y Redo
CTRL + Z Undo
DEL Delete
ENTER or F2 Displays the Modify Variable dialog for the selected watch variable,
which enables you to modify the value of that variable.
CTRL + SHIFT + F5 Restarts the current script beginning with the line at which it was
stopped using the Break command.
F6 If the watch pane is open, switches the insertion point between the
watch pane and the edit pane.
SHIFT + F9 Displays the Add Watch dialog, in which you can specify the name of
a BasicScript variable. The Script Editor then displays the value of
that variable, if any, in the watch pane of its application window.
F10 Steps through the script code line by line without tracing into called
procedures.
F11 Steps through the script code line by line, tracing into called
procedures.
CTRL + BREAK Suspends execution of an executing script and places the instruction
pointer on the next line to be executed.
SHIFT + F5 Build/Run
F7 Build
F10 Step
CTRL + C Copy
CTRL + E Clear
CTRL + F Find
F3 Find again
CTRL + I Import
CTRL + P Print
CTRL + R Replace
CTRL + T Font
F4 Replace again
CTRL + V Paste
CTRL + X Cut
CTRL + Z Undo
Browser Shortcuts
Table 8 Browser Shortcuts
Index 573
Transition stereotype 284 Adding Icons to a Diagram 83
Transitions 283 Adding instances 301
Trigger Specification 280 Adding stereotypes to the diagram toolbox 548
actor Add-ins 561
creating 143 Add-ins menu 75
specification 144 Aggregating and decomposing state
Actor specification 144 machines 235
actor, creating an 143 aggregating state machines 235
Add Capsule command 66 aggregation 159
Add Class Dependencies wizard 168 creating relationships 160
Add Classes command 66 aggregation relationships, creating 160
Add commands 66 Aggregation Specification 162
Add Components command 67 Aggregation tool 151
Add Interfaces command 67 analysis and design 26
Add Protocols command 67 Animation 488
Add Use Cases command 67 Application window 37
Add Watch command 73 browsers 37
AddCodeImportProperties 394 diagrams 38
Add-In Manager 75 menu bar 38
Add-In Manager dialog 561 Toolbar 38
adding toolboxes 38
capsule role 219 Application-specific command line
choice point 242 arguments 510
class dependencies 63, 449 Apply Label operation 413
code to model elements 112 Assigning an active component 440
color to an FOC 320 assigning an active component 440
documentation to model elements 111 association
files to source control 406 changing direction 170
FOC 309 End A defined 155
Focus of Control 309 End B defined 155
icons to a diagram 83 properties 155
instance to sequence diagram 301 association class 152
states 242 creating 162
stereotypes to Diagram Toolbox 548 association class, creating an 162
tags to Code 393 Association Properties 155
Adding a capsule role 219 association relationships, creating 154
Adding a choice point 242 association role
Adding a state 242 association 227
Adding and hiding classes, and filtering class multiplicity 227
relationships 171 stereotype 227
adding classes Association Role Specification 226
class Association Role tool 225
adding 178 Association specification 155
Adding code to model elements 112 Association tool 151
Adding documentation to model elements 111 association, changing the direction of an 170
574 Index
associations browser shortcuts 571, 572
creating relationships 154 Browser tab 559
asynchronous send message tool 309 Browser, displaying the 81
attach console 485 Browsers 37, 78
attach target 485 RTS 485
Attach Target option 483 browsers 37
Attaching a Model Property Set to a Single Ele- browsers, multiple 81
ment or a Collection of Elements 563 Build and RTS Shortcuts 570
Attribute Specification 345 Build basics 439
attributes build errors 114, 463
changeability 347 Capsule Role name same as Capsule
copying 97 name 464
creating 97, 334 Check Environment Variables 465
derived 347 Compile Fails on Valid C++ Models with
initial value 347 VC++ 5.0 or VC++ 6.0 467
moving 97 Compiler not installed correctly 464
naming 430 Ensure that Component has correct Make
specification 345 types configured 465
types 347 Error Linking Capsule (error from
visibility 346 nmake) 467
Attributes tab 96 Linking 468
attributes, creating new 334 Linking wrong Services Library set 464
automatically saving build results 469 Missing Class Dependencies 464
AutoSave 469 Missing Header Files, Object Files, and
Libraries 466
name conflicts 466
B Redefinition of basic types or multiple decla-
rations for X 463
Background Popup menu 84
Review your compiler flag settings 465
basic mode
Source File Compilation 467
Windows CE 518
System does not understand the make
basic_string template 202
command 465
Break 198
understanding 463
breakpoints
Unknown command, command not found,
diagram 503
the name specified is not
setting 500
recognized 463
setting for operations 507
unknown compiler message stream 451
setting on state machine without TO 501
Unresolved symbol or undeclared
state machines 501
identifier 463
Browse
Windows NT Compilation Command Line
Find References 94
Limits 467
Browse Button 335
Build Errors tab 114, 451
Browse menu 57
filtering results 114
Browse menu operations 58
sorting results 114
Browser Shortcuts 571
Build log 113
Index 575
build log 450 capsule
importing from 470 attributes
Build Log tab 113, 450 attributes
saving output to a file 113 capsule 357
Build menu 61, 447 definition of 20
build output moving multiple 372
saving 113 naming 430
build results operations 356
filtering 114 ports 359
sorting 114 stereotype 355
build results, reviewing 444 use 20
Build Settings dialog 450 capsule class
build shortcuts 570, 572 creating 353
build, starting a 441 Capsule class, creating a 353
Building 439 capsule connectors 359
building capsule diagram
add class dependencies 449 undocking 354
assigning an active component 440 Capsule diagrams 354
automatically saving build results 469 capsule diagrams, undocking 354
basics 439 capsule instance
Component wizard 450 dragging into a trace 495
errors 451 Capsule instance folder 487
importing model compilation results 468 capsule instance folder 487
Load command 449 Capsule Instance trace 491
log 450 Capsule instance trace 494
models 437 capsule instance trace 494
rebuild 448 capsule instances, dragging into a trace 495
Reload command 449 capsule role
Restart command 449 adding 219
reviewing results 444 cardinality 220
run 448 class 219
saving output 468 fixed 220
settings 450 name 219
Shutdown command 449 plug-in 220
Start command 448 specification 219
starting 441 substitutable 220
Stop command 448 Capsule Role Specification 219
top-level capsule 440 Capsule Role tool 212
Building and running models 437 capsule role tool 225
capsule role, adding a 219
capsule roles 358
C capsule roles, connecting ports together 221
Capsule specification 354
call message 309
Capsule Specification—Attributes tab 357
Calls command 74
Capsule Specification—Capsule Roles tab 358
576 Index
Capsule Specification—Components tab 360 CHello_construct 196
Capsule Specification—Connectors tab 359 choice point
Capsule Specification—Details tab 356 adding 242
Capsule Specification—Files tab 360 conditions 237
Capsule Specification—General tab 355 specification 237
Capsule Specification—Operations tab 356 Choice Point Specification 237
Capsule Specification—Ports tab 359 Choice Point tool 234
Capsule Specification—Relations tab 360 choice point, adding a 242
capsule state diagram class
creating 229 attributes 341
capsule state machines, creating 229 capsule role 219
capsule structure 207 creating 333
capsule structure diagrams 21 creating stereotypes 548
capsule structure, creating 207 hiding 178
Capsules 20 multiplicity 337
capsules naming 430
components 360 nested 342
relations 360 persistence 338
Capsules, protocols, ports, capsule state and class dependencies, missing 464
structure diagrams 19 Class diagram editor, using the 146
cardinality 221 Class diagram toolbox 149
capsule role 220 Class diagram, creating a 145
port 214 class operations
port role 218 implementation 340
Cascade command 76 private 340
change management 27 protected 340
Change View Spread public 340
Constant Radial 69 show inherited 340
Decreasing Radial 69 stereotype 340
Increasing Radial 69 visibility 340
Uniform 69 Class Specification 335
Change View Spread command 69 class specification
changing association direction 170 abstract 339
Changing the direction of an association 170 concurrency 338
Check environment variables 465 formal arguments 339
Check in operation 412 implementation 337
Check Model command 70 language 337
check out private 337
unreserved 416 protected 337
Check out operations 411 public 337
checking out files stereotype 336
when edited 405 type 336
with secondary edits 406 visibility 337
checkout Class Specification content 335
unreserved 416 Class Specification—Attributes tab 341
Index 577
Class Specification—Components tab 344 Code Sync 187
Class Specification—Detail tab 337 considerations 189
Class Specification—Details tab 345 disable 188
Class Specification—Files tab 345 enable 188
Class Specification—General tab 336 code sync
Class Specification—Nested tab 342 designated areas 534
Class Specification—Operations tab 339 disabling 533
Class Specification—Relations tab 344 enabling 533
class, creating a 333 identification tags 533
classes limitations 532
generating component libraries 180 overview 531
generating instantiated 200 using 532
generating parameterized 200 Code window 110
instantiated 203 code, adding to model elements 112
moving multiple 372 CodeCycle 393
relationships 203 CodeSyncEnabled 189
classes or diagrams, impact of moving on config- collaboration diagram
uration management 375 creating 222
classes, adding and hiding and filtering editor 222
relationships 171 toolbox 224
classesparameterized 201 Collaboration diagram editor, using the 222
classifier role Collaboration diagram toolbox 224
classifier 226 collaboration diagram, creating a 222
specification 225 Collaboration diagrams, opening 306
stereotype 226 collaboration relationships 223
Classifier Role Specification 225 collaborations and sequences, relationship
Classifier Role tool 225 between 223
Cloning a Sequence diagram 302 Coloring Focus of Control 320
cloning a sequence diagram 302 Column check boxes 496
code editor shortcuts 570 command line
Code generation 223 application-specific arguments 510
code generation 223 arguments 509
state machine 178 using 509
code import process 386 Command line arguments 509
analyzing the Code 391 command line arguments,
importing code 394 application-specific 510
launching the C++ Analyzer 387 Command Line Debugger 483
preparing the Rose model 386 command line parameter 508
selecting a source file location 388 common build errors, overview 463
specifying Export Options 388 Compartments tab 558
using CodeCycle to Add Tags to Code 393 Compilation 18
Code pane 110 Compilation Command Line Limits, Windows
NT 467
578 Index
compilation results 468 runtime exception 497
importing 468 shutdown 484
saving 468 unload 484
Compile a simple Hello World program 465 utility scripts 511
Compile fails on valid C++ models with VC++ 5.0 Component instance menu 484, 509
or VC++ 6.0 467 component instance menu 484, 509
compiling component instance options
code externally 535 basic 513
Component Debugger MSDEV 513
step 62 Debugger Tornado 513
component Debugger xxgdb 513
assigning for building 440 Manual 514
dependencies 461 Windows CE 514
load 63 Component Instance specification 511
rebuild 61 Component Instance Specification—Detail
reload 63 tab 512, 515
run 62 Component Instance Specification—General
settings 63 tab 511
shutdown 63 component instance, creating a 476
start execution 62 component instance, observing a running 481
stereotype 452 component instance, running a 479
stop execution 62 component instance, run-time exception while
Component Dependencies 461 running a 497
component diagram component instances, loading and running on
dependency 378 embedded targets 510
editor 377 Component Specification 451
toolbox 379 Component Specification—Files tab 453
Component diagram editor, using the 377 Component Specification—General tab 452
Component diagram toolbox 379 Component Specification—References tab 452
component instance Component Specification—Relations tab 453
attach console 485 component, creating a 441
attach target 485 Components tab 97
creating 476 Concurrency 291, 338
detach target 485 concurrency
error call stack length 515 active 338
load 484 class 338
operation mode 512 guarded 338
parameters 512 sequential 338
reload 484 synchronous 338
restart 484 Condition tab 237
run 484 configuration 27
run with Purify 484 configuration management
running with Purify 477 impact on moving classes or diagrams 375
running without Purify 479 Configure command 72
ConfigureFromRoseProperties 396
Index 579
configuring copying triggers 236
Tornado 2 for debugger mode 522, 524 co-region tool 310
Tornado for debugger mode 522, 524 Create 30
conflicts when demoting 165 Create New Model 39, 45
conflicts when promoting 165 Create New Model dialog 30
conjugated Creating
port 215 ports 212
port role 218 creating
connecting Activity Diagrams 260
ports on capsule roles 221 actors 143
Connecting ports on capsule roles together 221 association class 162
connection association relationships 154
characteristics 527 attributes 334
connection delay 515 capsule and protocol aggregations 148
Connector Specification 221 capsule class 353
connector specification 221 capsule state diagram 229
cardinality 221 capsule structure 207
delay 221 classes 333
Connector tool 212 collaboration diagram 222
connectors component instance 476
capsules 359 component instance tasks 476
Constraint tool 92, 150, 211, 224, 233, 309 custom framework (stereotypes) 544
ConstructFunctionName 196 dependency relationships 167
Constructing Models in Rational Rose inheritance relationships 162
RealTime 22 inheritance tree 163
constructors 195 inject messages 528
contacting Rational customer support xxx model property set 564
Containment View tab 80 nested activities 265
continuation junction point 238 nested states 248
Continue 198 new attributes 97
Controlling how existing stereotypes are dis- new operations 340
played in a diagram 549 non-wired port using a system protocol 213
Controlling how stereotypes are displayed in the Object Flow 293
browser 549 operations 100
Controlling how stereotypes that are added to operations
diagrams hereafter are displayed 550 creating 334
Controlling the display of stereotypes 549 package relationships 170
convert a component 397 packages 367
Convert Rose Component Wizard 397 realize relationships
copying realize relationships
operations 100 creating 171
copying attributes 97 reflexive relationships 170
copying signals 363 relationships 153
scratch pad packages 103
sequence diagram 299
580 Index
sequence diagram from a trace 492 Creating capsule state machines 229
sequence diagram from message trace Creating capsule structure 207
traces Creating dependency relationships 167
creating sequence diagram from Creating inheritance relationships 162
message trace 495 Creating nested states 248
stereotype (new) 544 Creating new attributes 334
stereotype configuration file 545 Creating new operations 334
stereotype for all Rose RealTime models 545 Creating package relationships 170
stereotype icons 548 Creating reflexive relationships 170
stereotypes 543 Creating relationships 153
stereotypes for Classes 548 creating sequence diagram
swimlanes (Activity Diagrams) 287 from browser 300
use case 141 from collaboration diagram 300
use case diagram 137 from structure diagram 300
Creating a Capsule class 353 from structure diagram browser 300
Creating a class 333 Creating sequence diagrams
Creating a Class diagram 145 from the browser 300
Creating a collaboration diagram 222 from the collaboration or structure
Creating a component 441 diagram 300
Creating a component instance 476 from the Structure diagram browser 300
Creating a custom framework 543 Creating stereotype icons 548
Creating a diagram icon 549 Creating stereotypes for classes 548
Creating a link 542 cross-references 403
Creating a new diagram 299 Customize Toolbar dialog 561
Creating a New Model Property Set 564 Customizing the diagram toolbox 561
Creating a new stereotype configuration file 545
Creating a new stereotype for all Rose RealTime
models 545 D
Creating a new stereotype for the current data classes
model 544 state machine 178
Creating a non-wired port using one of the sys- debugger
tem protocols 213 unloading 525
Creating a package 367 debugger mode
Creating a port 212 Tornado 522, 524
Creating a Sequence diagram 299 Tornado 2 522, 524
Creating a sequence diagram from a message Windows CE 522, 523
trace 495 xxgdb (Unix only) 524
Creating a use case 141 debugger modes 521
Creating a use case diagram 137 debugging
Creating aggregation relationships 160 breakpoints 500
creating aggregation relationships 160 importing model compilation results 468
Creating an actor 143 setting breakpoints 500
Creating an association class 162 source code 498
Creating an inheritance tree 163 Debugging Shortcuts 569
Creating association relationships 154
Index 581
decisions (Activity Diagrams) 271 diagram toolbox, customizing the 561
decomposing state machines 235 diagram types
Defining messages 302 Activity 257
defining messages in a sequence diagram 302 class 58
Defining state transition trigger events 246 collaboration 58
delay for connector specification 221 component 58
deleting deployment 58
messages from trace 491 sequence 58
swimlanes 287 state 58
Deleting a Model Property Set 564 structure 58
Deleting messages 491 use case 58
demote diagram, inserting into an MS Word
conflicts 165 document 541
demoting elements 165 Diagrams 24, 38
dependencies Activity 257
component 461 Capsule 354
dependency relationships State 354
creating 167 diagrams 38
dependency relationships, creating 167 Diagrams tab 120
Dependency Specification 168 Dialog
deployment diagram Activity Specification 268
components 382 Dialogs
connections 381 Build Settings 450
devices 381 Customize Toolbar 561
editor 380 Event Editor 239
elements 381 Find 105
packages 382 Generate Documentation 540
processors 381 Options 550
toolbox 382 Replace 106
Deployment diagram editor, using the 380 Select Diagram 57
Deployment diagram elements 381 Sequence Validation 318
Deployment diagram toolbox 382 disable code sync 188
Description window 109 disabling
Description window, displaying the 109 code sync 533
designated code sync areas 534 display a nested class 343
destroy message tool 310 Displaying or Editing a Specific Model Property
detach target 485 Set 564
Development process 25 Displaying or Modifying the Values of Model
development process 25 Properties 562
Device specification 517 Displaying the Browser 81
device specification Displaying the Calls dialog 74
characteristics 526 Displaying the Description window 109
Diagram editors 82 docking 81, 110
diagram icon, creating a 549 documentation
Diagram tab 143, 555 linking 539
582 Index
Documentation pane 110 error log
Documentation Report command 66 validation 319
Documentation window 110 errors 463
documenting Cannot code-sync 537
model elements 111 Cannot code-sync filename beyond line
Dragging capsule instances into a trace 495 lineNum 537
Drawing the initial transition 245 Capsule Role name same as Capsule
Drawing transitions between states 242 name 464
Check Environment Variables 465
Compile Fails on Valid C++ Models with
E VC++ 5.0 or VC++ 6.0 467
Compiler not installed correctly 464
Edit menu 49
Could not find trailing CodeSync tag for 537
editing
Ensure that Component has correct Make
checked out files 406
types configured 465
Editing a diagram 300
Error Linking Capsule (error from
Editing diagrams 542
nmake) 467
Editor tab 559
Linking 468
elements 165
Linking wrong Services Library set 464
demoting 165
Missing Class Dependencies 464
deployment diagram 381
Missing Header Files, Object Files, and
exporting 399
Libraries 466
moving 75
name conflicts 466
elements, required 22
Redefinition of basic types or multiple decla-
embedded targets 510
rations for X 463
enable code sync 188
Review your compiler flag settings 465
enable source control 405
Source File Compilation 467
enabling
System does not understand the make
code sync 533
command 465
End A and B Detail tabs 158
Unknown command, command not found,
End A and B General tabs 157
the name specified is not
End A defined 155
recognized 463
End B defined 155
Unresolved symbol or undeclared
end port 215
identifier 463
end state
Warning
Activity Diagrams 274
Use tabs for indenting code-sync
Ensure that component has correct make types
regions 537
configured 465 Windows NT Compilation Command Line
Entry Actions / Exit Actions 234 Limits 467
entry actions (state diagram) 234 Essential workflows 26
Environment 180 Event Editor dialog 239
environment settings 132 EventGuard 240
error Exclusions 163
call stack length 515 Executable models 21
Error linking Capsule (error from nmake) 467 executable models 21
Index 583
Executing 439 Find tab 115
Execution basics 476 finding
execution control 486 procedure calls 74
Execution control and information pane 486 Finding Specified Text 74
execution overview 476 fixed capsule role 220
execution watch 496 fixing a model 134
Execution Watch tab 496 floating 81, 110
exit actions (state diagram) 234 FOC 309
Expand Selected Elements command 67 activators 319
Export command 71 adding color 320
export control 169 definition 319
export options 388 Focus of Control 319
exporting adding 309
elements 399 definition 319
file 399 Focus of Control, coloring 320
files 399 Font/Color tab 554
Exporting a file 399 friend 160
external library 396 functions
externally visible junction point 238 main() 19
virtual 198
Further reading 23, 25, 26, 27
F
file history 414
file I/O error on
G
537 General Shortcuts 565
File menu 45 generalization 152
File menu operations 45 Generalize Specification 163
file, importing a 385 Generate 472
files Generate Documentation dialog 540
importing 385 Generate local state information 493
Files tab 98 GenerateDefaultConstructor 197
Filter Relationships command 68 GenerateStateMachine 186
filtering 81 generating
Build Results 114 Component Libraries for Classes 180
filtering class relationships documentation 539
class relationships state machine code 185
filtering 178 generating documentation
Filtering tab 558 inserting diagram into MS Word
final state 178 document 541
Final State tool 233 OLE 542
Find report options 540
references 94 Get Entire Model command 72
Find dialog 105 Get operation 411
Find References 94, 335, 361 global packages 370
584 Index
Go To Line command 74 importing requirements (ObjecTime
Graphical notation 168 Developer) 133
guard code 241 in signal 362
Guarded 338 Inheritance
guarded operation 351 Rose RealTime 164
inheritance
demoting 165
H excluding elements 165
promoting 165
Help menu 77
rearranging hierarchies 166
Hide Selected Elements command 68
re-inheriting excluded elements 166
hiding classes 178
virtual 164
history 199
Inheritance in Rose RealTime 164
activity 99, 267, 278
inheritance relationship
state 99, 267, 278
creating 162
sub activity 99, 267
inheritance relationships, creating 162
sub state 99, 267
Inheritance tab 80
inheritance tree 163
inheritance tree, creating an 163
I initial state
icons, adding to a diagram 83 specification 237
identification tags for code sync 533 Initial State Specification 237
IDH_EVENT_EDITOR_DIALOG 239 initial transition
Impact of moving classes or diagrams on configu- drawing 245
ration management 375 initial transition, drawing the 245
Implementation 349 inject
implementation of workflow 27 creating messages 528
Import Code command 71 inject data format
import log messages 134 basic types 529
importing classes 529
Classic C++ code from Rose 386 inject messages
code 394 creating 528
compilation results 471 Inject window 494
elements 385 inject window 494
files 385 injected data format 528
from Build Log 470 injecting a message 530
model compilation results 468 Injecting Messages 483
process 386 inserting
Rational Rose Generated Code 136 diagram into MS Word document 541
Rose generated code (Limitations and Inserting a diagram into an MS Word
Restrictions) 136 document 541
Importing a file 385 Inserting a link 542
importing model compilation 468 Instance browser 498
Importing Rational Rose generated code 136 instance browser 498
instances, adding 301
Index 585
instantiated class 153 Limitations and restrictions of opening models
instantiated class utility 153, 336 from Rational Rose 135
instantiated classes 203 link element 156
interaction link, creating a 542
specification 311 link, inserting a 542
stereotype 311 Linking 468
interaction instance linking
path 310 external files to model elements 539
specification 310 Linking external files to model elements 539
stereotype 311 Load command 449
Interaction Instance Specification 310 load component instance 484
interaction instance tool 309 loading
Interaction Specification 311 component instance on embedded
interface scripts 407 targets 510
internal transition 235 Loading and running component instances on
Introduction to Naming Guidelines 429 embedded targets 510
Introduction to packages 367 local action
Is Rose RealTime a compiler? 438 receiver 312
sender 312
stereotype 312
J Local Action Specification 312
local state
Joining transitions 247
receiver 313
joining transitions 247
sender 313
junction point
stereotype 313
continuation 238
Local State Specification 312
externally visible 238
Lock Selection tool 92
specification 238
log reports
Junction Point Specification 238
interpreting for Purify 479
Log tab 112
Logical View
K moving model elements 75
keys 160
M
L main() function 19
Language/Environment tab 560 make 472
Languages and code generation 18 make_command 472
Layout tab 122 Makefile pattern 188
Limitations and restrictions of importing Rational Making a Model Property Item Specific 563
Rose generated code 136 Managing model properties 562
Limitations and restrictions of opening models managing model properties 562
from ObjecTime Developer 5.2.1 133 Menu bar 38, 44
menu bar 38
586 Index
Menus 43 model elements
add-ins 75 adding code 112
Browse 57 moving 75, 372
Build 61, 447 Model Elements tab 371
Component instance 484, 509 model elements, adding documentation to 111
Edit 49 model management 468
File 45 model properties
Help 77 managing
Popup 111 model
Pull-down 111 managing properties 562
Query 66 Model Properties, displaying or modifying the
Report 64 values of 562
Tools 68 model properties, managing 562
View 56 Model Property Item, making one specific 563
Window 76 Model Property Set, creating a new 564
menus Model Property Set, deleting 564
Background Popup 84 Model Property Set, displaying or editing a spe-
message cific one 564
receiver 314 Model View tab 80
sender 313 modeling
message details, specifying 302 elements 22
Message Specification 313 required elements 22
Message trace configuration dialog 496 using Activity Diagrams 258
messages reorienting 306 Modeling elements 22
messages, defining 302 models
messages, deleting 491 building 437
messages, moving 307 creating stereotypes 545
Missing class dependencies 464 executable 21
Missing header files, object files, and running 437
libraries 466 models, building and running 437
mode models, constructing in Rose RealTime 22
debugger 521 Modify Variable command 73
xxgdb for debugging 524 Monitors 488
Model monitors
specification 129 animation 488
model monitors, opening 489
cross-references 403 Move Model Elements 75
opening 129 moving attributes 97
properties 562 moving classes
setting to improve opening time 406 impact on configuration management 375
unique Id 125 moving diagrams
unique ids 125 impact on configuration management 375
validation scenarios 404 Moving messages 307
moving model elements 372
moving operations 100
Index 587
Moving the Insertion Point to a Specified Line in Note anchor tool 92, 212, 225, 233
Your Script 74 Note tool 211, 224, 308
moving triggers 236 notification
Multiple Browsers 81 port 216
multiplicity 158
association role 227
class 337 O
multiplicity from 169
object flow 290, 291
multiplicity to 169
object state 291
Object State changes 292
ObjecTime Developer 5.2.1, opening models
N from 132
Name 429 Objects 290
Name conflicts 466 objects (Activity Diagrams) 290
name direction 157 observability 508
names Observability command line parameter 508
assigning 429 observability command line parameter 508
guidelines 429 Observability interface 483
special case notes 430 observability interface 483
Naming 168 observability options 483
naming attach target observability on startup 514
considerations 430 delay 514
naming guidelines 429 load 514
naming guidelines, introduction to 429 order 514
navigable 160 run 514
Navigating 80, 542 target observability port 514
navigating 80 observability options, overview of 483
nested Observing a running component instance 481
states 276 OLE
nested activities 265 creating a link 542
nested class 342 inserting a link 542
deleting 343 using 542
displaying 343 OLE, using 542
relocating 344 Online Help 1
nested states Open Script command 73
creating 248 Opening
nested states, creating 248 ObjecTime Developer model (limitations and
new diagram, creating a 299 restrictions) 133
New script command 73 Rose models (Limitations and
nmake 472 Restrictions) 135
nologo 472 opening
non-wired port, creating one using one of the sys- models 129
tem protocols 213 models from ObjecTime Developer 132
models from Rational Rose 134
588 Index
resolving model errors 134 Output window 112
Sequence Diagram 492 Overriding target control 482
Opening a Sequence diagram 223 overriding target control 482
Opening Collaboration diagrams 306 Overview Navigator 86
Opening models from ObjecTime Developer Overview of common build errors 463
5.2.1 132 Overview of observability options 483
Opening models from Rational Rose 134
Opening Sequence Diagram 492
Opening Specifications 84 P
operation mode (component instance) 512
Package 142
Operation Specification 347
package
operations
components 371
Apply Label 413
creating relationships 170
capsule 356
global 370
Check in 412
moving model elements 372
check out 411
relations 370
class 349
relationships 170
concurrency 351
specification 368
copying 100, 341
package relationships, creating 170
creating 100
Package Specification 368
exceptions 351
Package Specification dialog box 371
Get 411
Package Specification—Components tab 371
instance 349
Package Specification—Detail tab 370
moving 100, 341
Package Specification—Files tab 371
naming 430
Package Specification—General tab 369
options 349
Package Specification—Relations tab 370
parameters 350
package, creating a 367
protocol 350
packages
Refresh status 411
creating 367
return type 349
creating scratch pad 103
scope 349
overview 367
Show Differences 413
Packages and class diagrams 368
Show History 413
packages, introduction to 367
specification 347
Paper field 123
Submit all Changes 413
Parameterized Class tool 151
Synchronize 411
parameterized classes 201
Uncheckout 412
parameterized utility class 336
visibility 349
parent diagram 59
Operations tab 99
Parts menu
operations, creating new 334
Menus
Options dialog 550
Parts 54
Orientation field 123
Persistence 291, 338
out signal 362
persistence
output
class specification 338
redirecting 472
Index 589
Polymorphic 200 private
polymorphic operation 349 class specification 337
Popup menu 111 probe
port placing on replicated ports 494
cardinality 214 types 493
conjugated 215 usage 493
creating 212 Probe Break Points 483
definition of 21 Probe Specification 527
end port 215 Probe Specification—Detail tab 528
name 213 Probe Specification—Files tab 528
notification 216 Probe Specification—General tab 527
protected 216 probe types
protocol 214 port 493
publish 217 state 493
receiver 319 Probes 489, 493
registration 217 Probes folder 487
sender 319 probes folder 487
specification 213 procedure calls, finding 74
stereotype 214 processor
unwired 213 address 517
use 21 component instances 517
wired 215 CPU 516
Port Detail 314 load script 517
port probe 493 OS 516
port role server 517
cardinality 218 Processor specification 516
conjugated 218 Processor specification—General tab 516
specification 218 processors
Port specification 213 deployment diagram 381
Port tool 212 project phases 26
Port trace 491 promote
port, creating a 212 conflicts 165
Ports 21 promoting 165
ports promoting elements 165
capsule 359 protected
connecting to capsule roles 221 class specification 337
primary edits 403 port 216
print range 120 protocol 362
Print setup 123 port 214
Print Specifications 119 specification 361
Printer field 123 stereotype 362
printing Protocol specification dialog 361
range 120 Protocol Specification—Components tab 363
setup 123 Protocol Specification—Files tab 364
specifications 119 Protocol Specification—General tab 362
590 Index
Protocol Specification—Relations tab 363 Refresh Status of Model command 72
Protocol Specification—Signals tab 362 Refresh status operations 411
Protocols 20 refreshing shared unit status 406
protocols Refreshing the Browser 81
definition of 20 Refreshing the watch values 115, 497
moving multiple 372 refreshing watch values 115, 497
naming 430 registration
use 20 port 217
public class specification 337 re-inheriting excluded elements 166
publish Reinstalling the State and Value of the Last Com-
port 217 mitted Change 563
Pull-down menu 111 Related Documentation 2
Purify 477 Relations 143
log reports 479 Relations tab 101, 143
running component instance without 479 Relationship between collaborations and
sequences 223
relationships
Q between collaborations and Sequences 223
relationships, creating 153
qualifiers 160
reload 484
Query menu 66
Removing an Overriding Item Level Model
query operation 349
Property 563
Reorienting messages 306
Replace command 71
R Replace dialog 106
Rank 142 replicated ports
Rational customer support placing probes 494
contacting xxx Report menu 64
Rational Rose generated code, importing 136 Show Usage 64
Rational Rose, opening models from 134 report options
Real-Time services (Services Library) 438 generating documentation 540
RealTime Services Library 438 Required elements 22
rebuild 448 requirements 26
rebuild component 61 restart 484
receiver port 319 restart execution 486
redirect command 472 results 468
redirecting output results 472 Return 198
redirection_command 472 Review your compiler flag settings 465
referenced item 61 Reviewing the build results 444
referencing Rose RealTime dialog, About 39
External Library 396 Rose RealTime execution interface 482
refinement 200 rtBound 240
reflexive relationships 170 RTcompile 472
reflexive relationships, creating 170 rtg_init1 197
refresh execution 487 RTS browser 485
Index 591
RTS shortcuts 570, 572 Select Diagram dialog 57
RTS tab 80 Selective searching 107
rtUnbound 240 Selector tool 91, 150
Run command 448 Semantics tab 352
run component 62 send
run component instance 484 asynchronous message tool 309
running synchronous message tool 309
component instance 481 Send arguments 98, 271, 281
component instance on embedded Send target 98, 271, 281
targets 510 sender port 319
component instance with Purify 477 sequence diagram
component instance without Purify 479 add FOC 309
models 437 adding instances 301
outside the Toolset 508 asynchronous send message tool 309
Purify from outside the Toolset 508 call message 309
with Purify 484 cloning 302
Running a component instance 479 constraint tool 309
running component instance 477 co-region 310
Running from outside the toolset 508 create message tool 309
Run-time exception while running a component creating 299
instance 497 creating from browser 300
creating from collaboration diagram 300
creating from message trace 495
S creating from structure diagram 300
creating from structure diagram browser 300
saving
defining messages 302
automatically 469
destroy message tool 310
build output 468
editing 300
build output to a log file
Focus of Control 309
log
interaction instance tool 309
saving build output 113 local action tool 310
compilation results 468
local state tool 310
Scratch Pad Packages 103
moving messages 307
scratch pad packages
Note tool 308
creating 103
reorienting messages 306
Scratchpad 102
specifying message details 302
scripting shortcuts 568
synchronous send message tool 309
scripts directory 407
toolbox 307
Scroll Bars 85
using the editor 305
Searching and sorting 104
Sequence diagram editor, using the 305
Searching code 106
Sequence diagram toolbox 307
Searching for model elements by name 106, 107
sequence diagram, creating a 299
secondary edits 403
sequence diagram, creating one from a
Select Checked out Units in Browser
message 495
command 73
Sequence Diagrams 483
592 Index
Sequence diagrams, opening 223 source code debugging 498
Sequence Overlays 223 source control
sequence overlays 223 accessing operations 408
Sequence relationships 223 adding files 406
Sequence Validation dialog 318 Apply Label 413
Sequential 338 Check in 412
sequential operation 351 Check out 411
Services Library 19, 438 checking out files
setting automatically 405
breakpoints 500 checking out files automatically 406
shortcuts 565 enabling 405
browser 571, 572 Get 411
build 570, 572 interface scripts 407
code editor 570 location of interface scripts 407
debugging operations 410
debugging shortcuts 569 primary edits 403
general 565 Refresh status 411
RTS 570, 572 scripts directory 407
scripting 568 secondary edits 403
shortcuts, debugging 569 settings 404
Show Access Violations command 64 Show Differences 413
Show Code Occurrences command 65 Show History 413
Show Differences operation 413 status options 402
Show History operation 413 Submit all Changes 413
Show Inherited command 96 supported systems 407
Show Part Of Ancestors command 66 Synchronize 411
Show Part Of Descendants command 66 Uncheckout 412
Show References command 65 unreserved check out 416
Show Unit Versions command 73 versionable elements 407
Show Usage command 64 Source Control command 72
shutdown 484 source control status 402
shutdown execution 487 Source File Compilation 467
Signal Specification 364 Special Case Notes 430
Signal Specification—Files tab 365 Specification Code Editor Shortcuts 570, 572
Signal Specification—General tab 365 Specification Content 451
signals 362 Specification dialogs 92
copying 363 Specifications tab 121
data class 365 Specifications, opening 84
protocol 362 specify event 239
sorting specifying history 199
build results 114 Specifying message details 302
Sorting in the browser 104 Specifying the transition 245
Sorting in the class specification 104 Spreadsheet-type functionality for list controls
Source Code Debugging 483 within a specification dialog 93
Source code debugging 498 Start command 448
Index 593
start execution 486 states
Starting a build 441 creating nested states 248
startup options 551 step through execution 486
Startup screen 29 Stereotype 336
state stereotype 142, 156
adding 242 Activity Diagrams 273, 277
drawing transitions between 242 association role 227
end 274 capsule 355
history 99, 267 class operations 340
naming 430 class specification 336
start 274 classifier role 226
State Diagram 354 component 452
state diagram configuration file 545
aggregating 235 creating a new configuration file 545
choice point tool 234 creating icons 548
constraint tool 233 display 556
decomposing 235 icons (creating) 548
editor 230 interaction 311
elements 231 interaction instance 311
entry actions 234 local action 312
exit actions 234 local state 313
final state tool 233 message 313
Note anchor tool 233 port 214
Note tool 233 protocol 362
specification 234 stereotype icons, creating 548
state tool 233 stereotype, creating a new 545
state transition tool 233 stereotype, creating a new one for all Rose Real-
toolbox 232 Time models 545
transition to self tool 234 stereotype, creating a new one for the current
using the navigator 232 model 544
State diagram editor, using the 230 Stereotypes 543
State diagram toolbox controlling display 549
Toolboxes stereotypes
State diagram 232 adding to Diagram Toolbox 548
State diagrams 21, 246 creating 544
state machine creating a custom framework for models 543
data classes 178 creating for all Rose RealTime models 545
state machines, adding and decomposing 235 creating for classes 548
state probe 493 details 543
State Specification 234 stereotypes for classes, creating 548
State tool 233 stereotypes, controlling how existing ones are dis-
State trace 491 played in diagrams 549
State Transition tool 233 stereotypes, controlling how those that are added
state transition trigger events, defining 246 to diagrams hereafter are
state, adding a 242 displayed 550
594 Index
stereotypes, controlling the display of 549 target control 507
stereotypes, controlling their display in the overriding 482
browser 549 Target control programs 482
Stop command 448 target control programs 482, 517
stop execution 486 target display
Structure Diagram first occurrence only 516
Diagrams handles in use at exit 516
Structure 354 memory in use at exit 516
Structure Diagram toolbox 211 memory leaks at exit 516
Structure diagram toolbox 211 target scope 159
Structure Editor 208 targets
Structure editor, using the 208 loading and running 510
sub state 99, 267 tasks
Submit all Changes operation 413 creating a component instance 476
Submit All Changes to Source Control debugging source code 499
command 73 observing a running component instance 481
substitutable capsule role 220 running a component instance with
supported source control systems 407 Purify 477
swimlanes running component instance without
changing assignment responsibility 289 Purify 479
creating 287 TCKill 519
deleting 287 Text tool 91
displaying multiple views 288 The Script Editor Window 73, 74
moving 288 The toolbar 39
swimlanes (Activity Diagams) 286 Threshold field 496
synchronizations 281 threshold field 496
Synchronize Entire Model command 72 Tile Horizontally command 76
Synchronize Model with File System Tile Vertically command 76
command 73 To open a monitor 489
synchronize operations 411 Toolbar 38
Synchronous 338 toolbar 39
synchronous operation 351 create new model 39
synchronous send message tool 309 open existing model 40
syntax Toolbar button list 561
redirecting results 472 Toolbars tab 560
Toolboxes 38, 91
Class diagram 149
T Collaboration diagram 224
Component diagram 379
Tabs 80, 95
Deployment diagram 382
tags
Sequence diagram 307
adding to code 393
Structure diagram 211
target
Use case diagram 139
connection delay 515
default instrumentation type 515
Index 595
tools transition trigger event
constraint 92 define a new event in a protocol 246
lock selection 92 defining a new event in a capsule 246
note 92 defining a new event in a data class 246
note anchor 92 defining a new state 246
selector 91 transition, specifying the 245
text 91 transitions
zoom 91 Activity Diagrams 283
Tools menu 68 drawing an initial transition 245
Toolset dependencies 205 drawing between states 242
Toolset options 550 joining 247
Top-level capsule 440 specifying 245
top-level capsule transitions, drawing between states 242
capsule transitions, joining 247
top-level 440 trigger 178, 185, 239
Tornado trigger Stereotype 183
debugger mode for 522, 524 triggers
unloading debugger 522, 524 copying 236
Tornado 2 list 235
debugger mode for 522, 524 moving 236
unloading debugger 522, 524 Triggers tab 235
trace Troubleshooting
creating sequence diagram from 492 Import Log Messages 134
Trace configuration 491 troubleshooting
trace configuration 491 build errors 463
Trace window 490 Cannot code-sync 537
types 491 Cannot code-sync filename beyond line
Trace windows 490 lineNum 537
Traces 483 Capsule Role name same as Capsule
traces name 464
capsule instance 491, 494 Check Environment Variables 465
dragging capsule instances 495 Compile Fails on Valid C++ Models with
event message 494 VC++ 5.0 or VC++ 6.0 467
messages 491 Compiler not installed correctly 464
port 491 compiling a component 443
state 491 Could not find trailing CodeSync tag for 537
types 491, 492 Ensure that Component has correct Make
using different types 492 types configured 465
traces, when to use the different kinds of 492 Error Linking Capsule (error from
transition nmake 467
internal 235 Linking 468
specification 235 Linking wrong Services Library set 464
Transition Specification 235 Missing Class Dependencies 464
Transition to Self tool 234 Missing Header Files, Object Files, and
Libraries 466
596 Index
name conflicts 466 unloading
Redefinition of basic types or multiple decla- debugger 525
rations for X 463 unreserved check out 416
Review your compiler flag settings 465 unwired port
setting breakpoints 500 create using a system protocol 213
Source File Compilation 467 updating cross-references 403
System does not understand the make Usage tips 139
command 465 use case
unable to compile a component 443 creating 141
Unknown command, command not found, specification 141
the name specified is not Use case diagram editor, using the 138
recognized 463 Use case diagram toolbox 139
Unresolved symbol or undeclared use case diagram, creating a 137
identifier 463 Use case specification 141
Warning use case, creating a 141
Use tabs for indenting code-sync User-specific Working Environment Settings
regions 537 (.rtusr and .rtwks) 132
Windows NT Compilation Command Line Using OLE 542
Limits 467 Using sort 104
Tutorials 2 Using the Class diagram editor 146
Using the collaboration diagram editor 222
Using the Component diagram editor 377
U Using the Deployment diagram editor 380
UML Options 209 Using the Sequence diagram editor 305
UML options 209 Using the state diagram editor 230
Base UML notation 209 Using the structure editor 208
Show Classifier Name on Roles 209 Using the use case diagram editor 138
Show Protocol Name on Ports 209 Utility scripts 511
Uncheckout operations 412 utility scripts 511
Undocking the capsule diagrams 354
unidirectional aggregate association 152
unidirectional association 151 V
unique Id’s 125 Valid Applications 168
unique ids 125 validation error log 319
cautions 126 Validation tab 350
correct merge scenario 127, 128 View menu 56
incorrect merge scenario 127 virtual functions 198
model elements not having 125 virtual inheritance 164
unit information 407 virtual operations
Unit Information tab 101 overriding 200
Unknown compiler message stream 114, 451 Visibility 337
unload visibility
Windows CE component instance 521 implementation 349
Index 597
W X
Watch tab 115 xxdgb
watch values debugger mode 524
refreshing 497
Watches 483
watches Z
refreshing values 115
Zoom tool 91
WCESH3.bat for Windows CE 518
What’s This Help 1
When to use the different kinds of traces 492
Where to start 438
Window menu 76
Window Selectors command 77
Windows CE
Basic Mode 518
configuring a component instance 518
connection delay 520, 523
debugger mode 522, 523
location of script 519
RRT_WINCE_TARGET_DIR 519
Target Timeout 520, 524
tasks to configure component instance 518
unload 521
WCESH3.bat 518
Windows CE operation for component
instance 514
Windows NT Compilation Command Line
Limits 467
wired port 215
word wrap 110
workflow 26
analysis and design 26
change management 27
configuration 27
implementation 27
testing 27
workflows 26
working environment settings 132
Working with the Dialog Editor 74
workspace
definition of 131
598 Index