Module 7 - Sequence Diagrams Part 1 Flashcards
purpose of a sequence diagram is to define what kind of behaviors ?
interactions
T/F execution is instance of a defined behavior
True
7 common elements in a sequence diagram
- lifeline
- event occurrences
- Messages
- execution specification
- constraint
- combined fragment
7 _________ uses
interaction uses
Lifeline
is the ____ in the interaction behavior in a sequence diagram
participant
time travels down the ________
lifeline
what does the tail of a lifeline represent
a relative order of events / passage of time
is it legal for an interaction to be owned by a block ?
yes
a lifeline commonly corresponds to a part property or _________ of a block .
reference property
lifeline corresponds to a property of an owning block
each lifeline represents a single instance of its type.. never multiple ____
instances
a selector expression names a specific instance that the lifeline _________
represents
an instance specification [fc s/n 111] was assigned to be a selector __________
selector expression
the instance specification might not be nested in the same location as the interaction or owning block
behavior execution start and behavior execution termination is a kind of what ?
event occurrence
message send and message receive occurrence is a kind of
event occurrence
six kinds of event occurrences are
1. behavior execution start
2. behavior execution termination
3. Message sent
4. Message received
5 lifeline ______
6 lifeline ______
lifeline creation
lifeline destruction
where would you find a message send occurrence ?
look at the tail end of a message
where the tail end touches the lifeline
where would you find a message receive occurrence ?
look at the arrow end of a message
where the arrow end touches the lifeline
where would you find a lifeline creation event occurrence ?
at the arrow head end of a create event occurrence where there would be a new lifeline
where would you find a lifeline destruction event occurrence ?
end of a lifeline with an x
which means the end of a lifelines instance
what is the thin green line sitting on top of the lifeline ?
behavior execution
behavior starts executing at the top and bottom of the rectangle the behavior execution comes to an end
in an interaction a _________ represents communication between lifelines
message
overview of 7 messages found in a sequence diagram
Asynchronous
synchronous
reply
________
________
lost ( uncommon)
found ( uncommon )
create and delete
asynchronous messages - solid line with open arrow head which synchronous Messages are solid lines and
filled in arrowhead
reply and create message look similar
a create message touches the header of the lifeline
reply (shutdown) message touches both
lifelines
similarities of messages
- all messages appear as an arrow
- all messages represent communication
- each message defines two message
occurrences
a message sent - tail end
a messaged received - arrow head
T/F
message implies that data is being passed in a sequence diagram
False
asynchronous message = asynchronous invocation of a ______________
the client who send the message doesn’t wait for that message to arrive. Doesn’t wait for a reply to be sent back when the behavior comes to an end
behavior
difference between operation and reception
a reception represents a behavior that can only be invoked asynchronously
an operation represents a behavior that can only be invoked asynchronously or synchronously
tying back to sequence diagrams .. when you see a asynchronous message it could correspond to a message of the same name or it could correspond to an operation
which model element owns that matching operation or reception ‘measure Altitude’ … i.e dig around in the lifeline and see that the block owns that lifeline is mans
Mans has a matching reception with that measure Altitude name
Which model element owns that matching behavioral feature ( can either be a reception or operation )
the block that types the lifeline is the
owner
a reception has to correspond to a signal that is defined somewhere in the _________. The signals arrival is triggered by the matching reception .
model
Why is this answer correct ?
arrow solid line = asynchronous invocation also it is the receiving end of the message that is the performer of the message
therefore the block that performs the owning lifeline that owns the behavioral feature “Card inserted”
asynchronous message filled in line and open arrowhead
synchronous message filled in line and
filled in arrowhead
Firethruster is a
synch message
Review : Synchronous invocation means the client who invokes the behavior waits for it to finish and waits for control / objects to returned to it
In the diagram shown FC send the message and then waits for message to execute .. the performer of the behavior is PS then sends _________________
sends a reply message back to FC telling that the invoked behavior is now complete and can continue on the lifeline .
language law : each synchronous message must have a corresponding reply message .. its optional to ___________
if the exams asks you to count the message occurrences you would have to remember the hidden reply messages are implicitly there
display the reply message.
how many message occurrences are there in the diagram ?
8
T/F a operational can be either sync or async invoked ?
true
which model element is the owner of fire thruster
its not the lifeline itself .. there is nothing nested in the ps lifeline ..
look at what its typed by .. in this case
propulsion subsystem block
name of reply messages must ____
name : return value being sent to the client
match
why is initialize message violating language law ?
the message is being sent in a “blocked period of time” where FC is waiting for a reply message and synch behavior to be completed
Execution specification conveys what in a sequence diagram ?
that a lifeline is executing a behavior for some relative period of time .
a asynchronous message arrives and a behavior that the fc lifeline is executing.
T/F its optional to show a execution specification
True
when there is an overlapping execution specification what does that represent ?
represents a behavior that was invoked by measure altitude concurrently
one behavior is executing within the context of another behavior
conveys to the reader the period of time and multiple behaviors are executing on a lifeline.
event occurrences are found only on
lifelines
how many event occurrences are on the fc lifeline ?
7 .. message send and message receive are counted
1 message receive for create message
how many event occurrences are on the mansdd lifeline ?
#2 lifeline create event occurrence
#3 message receive for initialize ()
#4 behavior execution start
#5 message send initialize
#6 message receive initialize ( not shown)
#7 message send calibrate
#8 message receive calibrate ( not shown)
9 behavior execution end ( terminate)
#10 send initialize ready
1 Initialize send
how many event occurrences are on the mans lifeline ?
#2 behavior execution start
#3 behavior execution termination
#4 initialize send reply
5 Calibrate send
#6 behavior execution start
#7 behavior execution termination
#8 Calibrate send reply
Traces is an ordered sequence of event occurances
if there are 20 event occurrences th there are 20! different traces
event occurrences
two criteria for a trace to be valid
1) a message must be sent before it can be received
2) higher before lower on the same ____________
lifeline