CSPP 51090 & CMSC 22001: Software Construction Assignment 5
|Due: May 4, 2004|
The goal of this assignment is to improve the error checking and cheating detection of your scrabble adminstrator.
These error checks correspond to basic checks on cheating that the administrator and the players in a real game conduct. The terminology of cheating, though, is a notion in the application domain. The purpose of contracts is to catch basic errors in the development of software systems.
Presumambly you have protected your portions of the code (via modules or packages) so that the code itself is reasonably safe. We'll ignore issues like raising exceptions, non-termination for now -- the contracts below ensure that the players cannot cheat when following the protocol and ensure some basic guarantees for the players.
For some of the contracts, blame for failure lies with the player and for some, blame lies with the administrative infrastucture. For those where blame lies with the administrator, abort the program when a failure is detected. For those where the blame lies with the player, inform the player that they have violated the contract and kick them out of the game, but do not stop the game for any other players.
The following invariants govern the interactions in Scrabble:
Here are the three primary interfaces with sequence contracts:
|CSPP 51090 & CMSC 22001: Software Construction|