Prev Next

Expansion Region

A UML Region element.

Description

On an Activity diagram, an Expansion Region encloses a group of ActivityNodes and ActivityEdges that are to be executed several times on the incoming data, once for every element in the input collection. If there are multiple inputs, the collection sizes should match; if they do not, the smallest collection determines the number of executions. The collections must also be of the same type (such as set, or bag). Any outputs must be in the form of a collection of at least the same size as the input collection; the output collection can be larger if each execution can produce more than one output.

You create an Expansion Region as one variant of a Region (the other is an Interruptible Activity Region). When you drag a 'Region' icon from the Toolbox (on the UML Activity page, for example) a prompt displays for you to select the radio button for the variant you require, and to specify the concurrency of the Expansion Region's multiple executions (parallel, iterative or stream). Parallel reflects that the elements in the incoming collections can be processed at the same time or overlapping, whereas an iterative concurrency mode specifies that execution must occur sequentially. A stream mode Expansion Region indicates that the input and output come in and exit as streams, and that the Expansion Region's process must have some method to support streams.

To modify the mode of an Expansion Region, right-click on it and select the 'Properties | Special Action' option, then select the 'Advanced' tab and click on the drop-down arrow in the 'mode' field..

This UML Activity diagram illustrates the use of an Expansion Region to enclose a group of Activity Nodes and Activity Edges that are to be executed several times on the incoming data, once for every element in the input collection, in Sparx Systems Enterprise Architect.

Toolbox icon

Region element

Learn more

OMG UML Specification:

The OMG UML specification (UML Superstructure Specification, v2.1.1, p.367) states:

An expansion region is a structured activity region that executes multiple times corresponding to elements of an input collection.