|
JOT: Journal of Object Technology - Supporting Design by Contract in Java (5174 words) |
 | Postconditions are checked before invariants, but invariants are also evaluated in the case of exceptional method termination. |
 | Postconditions can refer to the old object state (this is the state at the time of method invocation) by using the special syntax @@(expr) and to the method’s return value by @@(). |
 | The postcondition method cannot be invoked in the finally block because it shall not be executed on exceptional termination. |
| Debugging Lab (1267 words) |
 | Postconditions for this message are that the pointy shape has been drawn, and the robot is standing on the tile furthest from the point on the lower or righthand line, facing away from the point. |
 | Postconditions for this message are that the tree has been drawn, and the robot is standing at the base of the trunk, facing away from the fork. |
 | The message’s postconditions are that the returned value is the number of tiles the robot can reach by moving forward or backward from its initial tile, including that initial tile, and that the robot is standing on the initial tile, facing in its original direction. |