state machines Flashcards

1
Q

state

A

condition the object stays in

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

trigger

A

the event that causes the transition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

guard

A

a conditional statement that must be true for an event to occur

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

event

A

action that happens due to the transition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

transition

A

moving from one state to the other
may have a trigger guard and effect

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what are two other dynamic uml diagrams

A

activity diagram
sequence diagram

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

activity diagram

A

a walk through from the user pov that models the flow of control

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

sequence diagram

A

specify interactions within the system
time based approach showing which components are active and when
also shows when components communicate with each other and any bottlenecks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

what do state machines do

A

model the behaviour of a thing and specifies the state it goes through during its lifetime in response to an event

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

what are some examples of the thing that state machines model the behaviour of

A

system/subsystem
instance of a class

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

what is the state of a class

A

its attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

what are some benefits of state machines

A

model what happens when an object gets a message
include events that lead to object changing state
helps test and maintain systems
useful for systems with lots of dynamic behaviour e.g. control and communication systems

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

what are the 3 event types

A

signal, call and time

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

signal event

A

real time receipt of a signal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

call event

A

operation call

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

time event

A

time based transition
e.g. a specific time or a time interval

17
Q

composite states

A

nested state that adds a substate
can be a single state at one level but can be viewed in higher detail
has its own start and stop

18
Q

concurrent states

A

states running in parallel using a fork and join

19
Q

what are the steps in building a state diagram

A

id the object and event that affect it
id possible states including the start and stop
check if events are conditional
id actions object perform in response to an even t
begin the diagram from the start state
build the diagram systematically via events and states
check for super or composite states