|Previous||UML Classes||Table of Contents||UML Packages||Next|
ReadLinkAction is a link action that navigates across associations to retrieve objects on one end.
LinkAction (from IntermediateActions ) on page 268
This action navigates an association towards one end, which is the end that does not have an input pin to take its object
(the open end). The objects put on the result output pin are the ones participating in the association at the open end, conforming
to the specified qualifiers, in order if the end is ordered. The semantics is undefined for reading a link that violates the
navigability or visibility of the open end.
No additional attributes
|result : OutputPin ||The pin on which are put the objects participating in the association at the end not specified by the inputs. (Subsets Action::output)|
 Exactly one link-end data specification (the open end) must not have an end object input pin.
self.endData->select(ed | ed.value->size() = 0)->size() = 1
 The type and ordering of the result output pin are the same as the type and ordering of the open association end.
let openend : AssociationEnd = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in self.result.type
and self.result.ordering = openend.ordering
 The multiplicity of the open association end must be compatible with the multiplicity of the result output pin.
let openend : AssociationEnd = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end inopenend.multiplicity.compatibleWith(self.result.multiplicity)
 The open end must be navigable.
let openend : AssociationEnd = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end inopenend.isNavigable()
 Visibility of the open end must allow access to the object performing the action.
let host : Classifier = self.context in
let openend : AssociationEnd = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in
openend.visibility = #public
or self.endData->exists(oed | not oed.end = openend
and (host = oed.end.participant
or (openend.visibility = #protected
Navigation of a binary association requires the specification of the source end of the link. The target end of the link is
not specified. When qualifiers are present, one navigates to a specific end by giving objects for the source end of the association
and qualifier values for all the ends. These inputs identify a subset of all the existing links of the association that match
the end objects and qualifier values. The result is the collection of objects for the end being navigated towards, one object
from each identified link.
In a ReadLinkAction , generalized for n-ary associations, one of the link-end data must have an unspecified object (the open
end). The result of the action is a collection of objects on the open end of links of the association, such that the links
have the given objects and qualifier values for the other ends and the given qualifier values for the open end. This result
is placed on the output pin of the action, which has a type and ordering given by the open end. The multiplicity of the open
end must be compatible with the multiplicity of the output pin. For example, the modeler can set the multiplicity of this
pin to support multiple values even when the open end only allows a single value. This way the action model will be unaffected
by changes in the multiplicity of the open end. The semantics are defined only when the open end is navigable, and visible
to the host object of the action.
No specific notation
ReadLinkAction is introduced to navigate across links.
ReadLinkAction is unchanged from UML 1.5.