-
Key: OCL2-9
-
Legacy Issue Number: 4112
-
Status: closed
-
Source: Anonymous
-
Summary:
Usually, the behaviour of an operation is described by pre and
postconditions, and then shown in a collaboration diagram. In turn, in a
collaboration diagram one can model (via the standard stereotypes create and
destroy) the creation and destroying of instances, but this is not in the
case in OCL. It would be useful to be able to explicitly model in a
postcondition that an instance ocurring in the expression was created during
the execution of the operation being specified. Since introducing a command
is not possible, this feature could be achieved by just 'declaring' in the
postcondition that the instance 'was created'.For example:
context X::operation()
post: self.attr = self.attr@pre->including(created p)this declares that p was created during the execution of operation, and it
was not taken from elsewhere. -
Reported: OCL 2.0b1 — Fri, 8 Dec 2000 05:00 GMT
-
Disposition: Resolved — OCL 2.0b2
-
Disposition Summary:
No Data Available
-
Updated: Sun, 8 Mar 2015 13:38 GMT