Activity Modeling and relating to Block Diagrams

Interruptible region = subset of actions within activity that can interrupt execution of activity via interrupting edge; noted by dashed line around activity nodes; an interrupting edge is noted by lightning bolt symbol; [21] interrupting edge node is within the interruptible region and this has to be triggered to exit the interruptible region;

 

 

Flow rates = any streaming parameter may have rate attached to it (expected rate of tokens that flow in or out of that pin or parameter node); continuous or discrete rates are indicated with keywords <<continuous>> or <<discrete>>.

 

 

[22] What does a flow rate of “25 per second ” on an activity edge indicate about the flow of tokens along that edge? A rate of 25 per second on an activity edge indicates that many tokens must be produced per second

Flow order = on pins with upper bound greater than 1, those tokens are queued there; that queue can be sorted based on FIFO, LIFO or unordered; if number of tokens exceed the upper bound, can set object node to overwrite tokens already in the queue (use keyword <<overwrite>>) or to discard the new ones (use keyword <<noBuffers>>);

[23] How would a modeler indicate that new tokens flowing into a full object node should replace tokens that already exist in the object node? How would a modeler indicate that new tokens flowing into a full object node should replace tokens that already exist in the object node? ANSWER = use keyword <<overwrite>>

 

Probabilistic flow = each alternative flow has probability value (of tokens taking that flow) and all flows must sum to 1;

 

 

 

 

Relating Activities to Blocks

Activity partition / swimlane = indicates actions in the partition represents a block or a part and its behaviors (maps to block); noted as rectangle boxes encompassing the actions; each box has a header with name string and model element represented in the partition (ex block name); In Figure 8.21 note that two different flow paths shown (control and object) – the object continues to flow right though the control may not;

 

 

[24] If a call behavior action is placed in an activity partition representing a block, what does this say about the relationship between the block and the called behavior?

If a call behavior action is placed in an activity partition representing a block, what does this say about the relationship between the block and the called behavior? ANSWER = the behavior maps to the block, how block is used to complete the behavior.

 

[25] Name the two different roles that an activity can play when owned by a block. ANSWER = activities as block behaviors and activities as methods

Activity in Block Context = activities can be owned by block; each instance of block executes the activity;

 

 

 

Activities as methods = supports two types of behavior = operation – supports synchronous/asynchronous requests; reception – supports only asynchronous request; methods are invoked when owning block instance consumes a request for the behavior – or through call operation action;

 

 

[26]Describe the four ways in which activities can be used as part of state machines.

Describe the four ways in which activities can be used as part of state machines. ANSWER = Activities are often used to describe these behaviors:

– What happens when STM enters a state (entry behavior)

– What happens when STM exits a state (exit behavior)

– What happens while a STM in a state (activity)

– What happens when state machine makes transition (transition effect)

 

 

Modeling Activity Hierarchies using Block Definition Diagrams

 

EFFBD = Enhanced Functional Flow Block Diagrams = activity diagrams