inf-2120 2005 rational software modeler / architect · inf-2120 2005 rational software modeler /...
Post on 16-Oct-2018
233 Views
Preview:
TRANSCRIPT
9-Feb-05 INF2120 Prosjekt i modellering 1
INF 2120
INF-2120 2005Rational Software Modeler / Architect
Version 090205Gøran K. Olsen
9-Feb-05 INF2120 Prosjekt i modellering 2
INF 2120
Today
Introduction to Rational Modeler / Architect Difference between diagram and modelClass diagramComposite StructureSequence diagramDifferent tutorials
9-Feb-05 INF2120 Prosjekt i modellering 3
INF 2120
UML Model
A UML model is a collection of UML elements, diagrams,and data such as relationships and requirementsinformation, that describe a real-world system.A software architect uses UML to build models that describe the quantifiable characteristics of a system such as the:
System's structure Behaviour Constraints Dependencies
9-Feb-05 INF2120 Prosjekt i modellering 4
INF 2120
Components of a UML model
Model elementsDiagram elementsDiagrams
9-Feb-05 INF2120 Prosjekt i modellering 5
INF 2120
Model elements
The building blocks of a UML model are called model elements.Model elements are the data representation of a real world object, actor, or system.
9-Feb-05 INF2120 Prosjekt i modellering 6
INF 2120
Diagram elements
A UML diagram contains diagram elements (sometimes called shapes)They visually describe the classifiers in a diagramThese classifiers are the diagrammatic representation of a model elementDiagram elements are not considered part of the semantic model
9-Feb-05 INF2120 Prosjekt i modellering 7
INF 2120
Diagrams
A UML diagram describes the quantifiable aspects of a system that can be visually describedSuch as: Relationships, behavior, structure, and functionalityFor example, a use case diagram describes the interactions between the users of the system, called the actors, and the system
9-Feb-05 INF2120 Prosjekt i modellering 8
INF 2120
Rational Modeller / Architect
9-Feb-05 INF2120 Prosjekt i modellering 9
INF 2120
IBM Rational® Software Architect
Provides a flexible development environment for creating and editing UML models. You can use the Model Explorer view to edit the source code and model structure of the semantic model. You can use the diagram editor to edit the visualized model. When you edit models, you should understand the differencesbetween model elements and diagram elements. For example, when you right-click an element in the diagram editor, there are two delete options. If you click Delete from Diagram, the element is deleted from the diagram only, because the diagram element is only a visualization of a model element. Conversely, if you click Delete from Model, the element is deleted from both the model and the diagram.
9-Feb-05 INF2120 Prosjekt i modellering 10
INF 2120
Eclipse platform workbench Java Perspective
9-Feb-05 INF2120 Prosjekt i modellering 11
INF 2120
Eclipse platform workbench Modeller Perspective
9-Feb-05 INF2120 Prosjekt i modellering 12
INF 2120
Create a new project
From File menuchoose :
1.New
2.Project
3.Modeling
4.UML Project
9-Feb-05 INF2120 Prosjekt i modellering 13
INF 2120
Model Editor
9-Feb-05 INF2120 Prosjekt i modellering 14
INF 2120
Creating a new class diagram
1. Right-click your model
2. Add Diagram
3. Class Diagram
9-Feb-05 INF2120 Prosjekt i modellering 15
INF 2120
Adding a class to your model (1)
Classes can be added
from the Model
explorer field:
1. Right click your new class model
2. Add UML
3. Class
9-Feb-05 INF2120 Prosjekt i modellering 16
INF 2120
Adding a class to your model (2)
From the Palette
on the right side of
your screen:
1. Left-click the class icon
2. Left-click or click and drag in the editor
3. Enter the name of the class
9-Feb-05 INF2120 Prosjekt i modellering 17
INF 2120
Adding a class to your model (3)Or simply holdthe mouse still in the editor:1. A menu will
appear2. Choose what
element you want to create
3. Enter element name
9-Feb-05 INF2120 Prosjekt i modellering 18
INF 2120
Adding attributes and operations to your classAttributes and operations can be added in different ways:1. By holding the
pointer over the class element for some seconds
2. Right-clicking the class in the Model Explorer view
3. Right-clicking the class element in the diagram
9-Feb-05 INF2120 Prosjekt i modellering 19
INF 2120
The Property view
Every element in a diagram has propertiesA class can be public, protected or privateAssociations have multiplicity, roles, types…A diagram has name and a type: DomainACSys <> classWe have the property tab / viewLet’s look at the association property view
9-Feb-05 INF2120 Prosjekt i modellering 20
INF 2120
Association property view
1. Click once at the association between two classes
2. Choose the property tab
3. Here we can change the roles, label and the multiplicity of an association
9-Feb-05 INF2120 Prosjekt i modellering 21
INF 2120
Composite Structure
Right-click class in Model ExplorerAdd diagramComposite structure diagramThe classes from the class diagram is now included (if any composition)Hold mouse on diagram element to create port or connector, (as shown)
9-Feb-05 INF2120 Prosjekt i modellering 22
INF 2120
Sequence Diagram
Create a new UML diagram the same way you created the class and the composite diagram. This is the palette that will appear. You can now drag and drop classes from the Model Explorer or create new classes
9-Feb-05 INF2120 Prosjekt i modellering 23
INF 2120
Sequence Diagrams Palette
Some alternatives have a drop-down arrow. Click this for different messages or combined frag-ments
9-Feb-05 INF2120 Prosjekt i modellering 24
INF 2120
Alternative Combined Fragments
Click on Option combined fragment arrowChoose altWhich operand decided by “[ ]”
9-Feb-05 INF2120 Prosjekt i modellering 25
INF 2120
Adding an operand
Right-click alt boxChoose Interaction OperandAdd before or after inserts a new alt
9-Feb-05 INF2120 Prosjekt i modellering 26
INF 2120
The world is NOT perfect
Rational Software Development Platform is a new toolØystein Haugen was a beta test-user and reported lots of errors and weaknessesSome of the errors are not yet fixedThis includes attaching messages to the frame in Sequence DiagramsDecomposition of lifelines (placing the Ref: ). One solution to this is just placing the ref in front of the object name in /**Ref: sd MakePayment**/ or attaching a noteContinuations not implemented.Execution occurrences appears automatically even when asynchronous messages are used. Annoying but just delete it from the model.
9-Feb-05 INF2120 Prosjekt i modellering 27
INF 2120
Example on how to fix shortcomings
Lifeline decompositionCreate an unspecified lifeline with no namePlace it on the side and connect the message “out of frame” to itContinuation
9-Feb-05 INF2120 Prosjekt i modellering 28
INF 2120
Smart things to remember
Window, Reset perspective: The workbench returns to its default view.Fast view. Drag the view to the right bottom of the screen. Then you can look at it with a simple click. When you click somewhere outside the view, it closes.Restore a fast view by dragging it back into the workbench.Double-clicking a tab maximises the view, again back to normal Help menu wasn’t made just for fun!Tutorials and samples: A good place to start!
9-Feb-05 INF2120 Prosjekt i modellering 29
INF 2120
IBM Modern Java development Workshop
Time: Wednesday 2. Mars Place: IBM Norway’s main office at KolbotnPrice: Free!What: Demonstration of modern Java development
with Eclipse and Rational Architect.
http://www-5.ibm.com/no/news/events/rational/java/
Could this be of interest ?
9-Feb-05 INF2120 Prosjekt i modellering 30
INF 2120
Questions?
top related