> Currently user B will get a message to say that this room is no longer bookable.
How does B's client know this?
The required interface in my assignment has this function:
// Modifies the fields of a record. The new value for field n
// appears in data[n]. Throws SecurityException
// if the record is locked with a cookie other than lockCookie.
public void updateRecord(long recNo,
String[] data, long lockCookie)
throws RecordNotFoundException, SecurityException;
The only way the server can communicate a result back to the client here is by throwing an exception. (or mangling with the provided String array, but let's not suggest that.)
The serverside could of course throw a RecordNotFoundException whenever a client updates a record that has been booked. But that means that any booking can never be changed.
How did you solve this?