Operation contracts
From Wikipedia, the free encyclopedia
| This article is orphaned as few or no other articles link to it. Please help introduce links in articles on related topics. (November 2007) |
| This article does not cite any references or sources. (November 2007) Please help improve this article by adding citations to reliable sources. Unverifiable material may be challenged and removed. |
| This article lacks information on the notability of the subject matter. Please help improve this article by providing context for a general audience, especially in the lead section. (November 2007) |
Operation contracts are formal constraints defined over software operations. These are created during the domain-modeling phase.
Typically, an operation contract consists of 4 components:
- Operation name: A name for the operation
- Cross-References: List of use-cases that refer this operation
- Preconditions: State of variables/system before this operation is invoked
- Postconditions: State of variables/system after successful completion of the operation
Typically, the Postconditions can be of 3 kinds:
- Instance creation
- Attribute modification
- Associations broken/added

