Previous UML Classes Table of Contents UML Packages Next


14.3.4 ConsiderIgnoreFragment

Fragments


*Generalizations

   

    CombinedFragment (from Fragments ) on page 487

*Description

   A ConsiderIgnoreFragment is a kind of combined fragment that is used for the consider and ignore cases, which require lists of pertinent messages to be specified.

Issue 8325 - add empty Attributes sub-section and fix heading for Associations

*Attributes

   No additional attributes.

*Associations

   • message : NamedElement [0..*] The set of messages that apply to this fragment.

*Constraints

   [1] The interaction operator of a ConsiderIgnoreFragment must be either ‘consider’ or ‘ignore.’

   (interactionOperator = #consider) or (interactionOperator = #ignore)

   [2] The NamedElement s must be of a type of element that identifies a message (e.g., an Operation, Reception , or a Signal).

   message->forAll(m | m.oclIsKindOf(Operation) or m.oclIsKindOf(Reception ) or m.oclIsKindOf(Signal))

*Semantics

   The interactionOperator ignore designates that there are some message types that are not shown within this combined fragment. These message types can be considered insignificant and are implicitly ignored if they appear in a corresponding execution. Alternatively, one can understand ignore to mean that the message types that are ignored can appear anywhere in the traces.

   Conversely, the interactionOperator consider designates which messages should be considered within this combined fragment. This is equivalent to defining every other message to be ignored.

*Notation

   The notation for ConsiderIgnoreFragment is the same as for all CombinedFragment s with the keywords consider or ignore indicating the operator. The list of messages follows the operand enclosed in a pair of braces (curly brackets) according to the following format:

   (‘ignore’ | ‘consider’) ‘{‘ <message-name> [‘,’ <message-name>]* ‘}’

   Note that ignore and consider can be combined with other types of operations in a single rectangle (as a shorthand for nested rectangles), such as assert consider {msgA, msgB}.

*Examples

   consider {m, s}: showing that only m and s messages are considered significant. ignore {q,r}: showing that q and r messages are considered insignificant.

   Ignore and consider operations are typically combined with other operations such as assert consider {m, s}. Figure 14.24 on page 532 shows an example of consider/ignore fragments.

*Changes from previous UML

   This concept did not exist in UML 1.x.