Advanced Systems Design with Java, UML and MDA

In this chapter we present a complete development of the online property search system, using the UML2Web synthesis tool. We also illustrate the automated generation of a JSP-based architecture for a web system.
The use cases of the property search system that we will synthesise code for are shown in Figure 10.1 and the abstract class diagram is shown in Figure 10.2.
The constraints of this system in LOCA are:
C1 'A user's minimum price must be at least 0, and less than or equal to
their maximum price choice':
0 ? userMinprice &
userMinprice ? userMaxprice
as a class invariant of User.
C2 'A property matches a user's requirements if its price is in their range, it is available, has at least as many bedrooms as they require, and is of the same type and in the same area as required':
userMinprice ? propertyPrice &
userMaxprice ? propertyPrice &
userArea = propertyArea &
userType = propertyType &
userBedrooms ? propertyBedrooms &
propertyAvailable = true
This defines the implicit association User_Property.
In addition to the class diagram and constraints, we also need to specify the operations that a user of the web system will be able to carry out. These are based on the use cases of Figure 10.1. The operations are therefore:
create User