Specifying Operations
Specifying Operations
Structured English
Activity Diagrams
Events transmitted to other objects describe the sequence of internal logical steps
that an operation is to follow.
Any attributes set
Non-Algorithmic Techniques describe the
Response to exceptions (e.g. an invalid parameter) result for a given set of inputs.
Non-functional requirements
steps
Decision Table: similar applications to decision tree
Is overspend likely to exceed 2%? - N Y condition combinations and the corresponding actions
Actions
that will occur for a specific combination.
No action X
Send letter X X
Set up
M8748 meeting
© Peter Lo 2007 X 13 M8748 © Peter Lo 2007 14
Activity Diagrams
Activities diagrams can be used to specify the An activity diagram showing the main steps for the
logic of procedurally complex operation. operation CreativeStaff.changeGrade().
OCL expressions usually consist of: Defines domain within which expression is valid
A Context within which the expression is valid Instance of a type, e.g. object in class diagram
(for example, a specified class); Link (association instance) may be a context
A Property within the context to which the
expression applies (for example, an attribute of
the specified class);
An Operation that is applied to the property
(for example, a mathematical expression that
tests the value of the attribute).