4' Design - PowerPoint PPT Presentation

1 / 18
About This Presentation
Title:

4' Design

Description:

Sequence diagram focuses on time, collaboration diagram focuses on space. ... Collaboration & Sequence Diagrams - Comparison. ... Collaboration Diagram Notation ... – PowerPoint PPT presentation

Number of Views:25
Avg rating:3.0/5.0
Slides: 19
Provided by: renaatve
Category:

less

Transcript and Presenter's Notes

Title: 4' Design


1
4. Design
  • 4.1 Sequence Diagrams
  • 4.2 Collaboration Diagrams
  • 4.3 Modelling Behaviour

2
Sequence Diagrams
  • Sequence Diagrams or Message Sequence Charts
    (MSC) are used in telecom. Standard from the
    former CCITT, now ITU for MSC, called X.100.
  • Good for illustrating a scenario, shows order or
    occurrence.

3
anOrderEntry Window
naOrder Line
aStock Item
anOrder
prepare()
prepare()
iterate
check()
condition
checktrue remove()
checkReorder()
self delegation
aReorder Item
new
needReordertrue
aDelivery Item
return
checktrue new
creation
4
Notes on the Diagram
  • Vertical line is lifeline.
  • Self delegation, object sends message to self.
  • Condition shown in .
  • Iteration marker is .
  • Return uses open arrowhead.
  • Activations not shown here, shown previously.

5
Collaboration Diagrams
  • Another form of interaction diagram.
  • An exact dual of sequence diagram
  • Illustrates links (instance of association) and
    interactions between Objects.
  • Sequence diagram focuses on time, collaboration
    diagram focuses on space.
  • Objects not classes are the focus here.
  • Links annotated with message label syntax.

6
Syntax Notes
  • Sequence of messages illustrated by numbering
    scheme. Several schemes available.
  • Object naming scheme where either one component
    may be omitted.
  • ObjectName ClassName

7
OrderEntryWin
1prepare()
Sequence Number
Order
1.1.2.2needToReorder()
1.1prepare()
1.1.1check() 1.1.2checktrueremove()
MacallanItemStockItem
MacallanLineOrderLine
1.1.2.2new
1.1.3checktruenew
ReorderItem
DeliveryItem
8
Collaboration Sequence Diagrams - Comparison .
  • Sequence Diagrams better for illustrating the
    order of occurrences, collaboration diagrams
    better for showing static connections.
  • A matter of personal preference.
  • Both forms lend themselves to scenarios.

9
Sequence Diagram
Computer
PrintServer
Printer
Queue
Print(file)
printer freeprint(file)
printer busystore(file)
10
Sequence Diagram Notation
  • Developed from ITU standard X.100 State
    Transition Diagram (STD) notation.
  • Portrays dynamic collaboration between objects.
  • Objects shown in boxes across top.
  • Time marches down the page.

11
Collaboration Diagram Notation
  • Collaboration may be illustrated on either a
    collaboration diagram(CD) or a sequence diagram
    (SD).
  • If sequence is important, then use SD, otherwise
    CD will put objects in context.
  • CD is hybrid between Object Diagram and sequence
    Diagram.
  • Ordering of messages may be illustrated.

12
Activity Diagram
Show MessageBox Disk Full
disk full
Print File()
Show MessageBox Printing
free disk space
Remove MessageBox
Create postscript file
Printer.Print(file)
13
Activity Diagram Notation
  • Shows sequential flow of activities.
  • May be used to illustrate use cases or
    interactions.
  • Control flows among action states without needing
    explicit events as in State Diagrams.

14
no coffee
no cola
Find Beverage
found Coffee
found cola
Add water to reservoir
Get Cups
Get Cola
Put Coffee in filter
Filter in machine
Turn on machine
coffeePot.turnOn
Brew coffee
lights Out
Drink beve
Pour Coffee
15
Activity Syntax Rules
  • Events may be attached only from the start point
    to the first activity.
  • Guard conditions, action-expressions and
    send-clauses may be optionally attached to the
    transition.
  • Transitions may be split and reassembled by using
    bars.
  • Swimlanes may be introduced

16
Using Swimlanes.
  • Activities may be grouped, showing which objects,
    or which departments in a company are responsible
    for them.
  • Drawn as rectangles or separated by hashed lines.

17
2.3.5 Sequence Diagram
Computer
PrintServer
Printer
Queue
Print(file)
printer freeprint(file)
printer busystore(file)
18
Sequence Diagram Notation
  • Developed from ITU standard X.100 State
    Transition Diagram (STD) notation.
  • Portrays dynamic collaboration between objects.
  • Objects shown in boxes across top.
  • Time marches down the page.
Write a Comment
User Comments (0)
About PowerShow.com