Anda di halaman 1dari 2

II. [30] Create a java based application that is a part of an airline ticketing system.

The GUI
shown below, you need not format the GUI (you however, should have all the elements shown).

Flight ID:

Origin:

Ticket Price

Destination:

Available Flights:

New Flight Timing:

Seats:

messages go here
System Message
[Search Button]

[ Modify Button] [New Flight Button] [ Save Button] [CancelButton]

The requirements for this simplified reservation system is as follows.

1. GUI [5]
2. When the form loads, the Origin and Destination combo boxes should be
filled with all available airports from the Airports Table. [5]
3. The user picks the origin and destination (they cannot be the same). The user
then clicks on Search Button. This should populate the Available Flight
Timings combo box. This data is got from the schedule table that contains the
timings for certain combination of airports (note: the combo box shows a
descriptive name, but this table uses the numeric ID) and also the seat
availability. [5]
4. The price box is filled based on the formula which uses the region code of the
airport. If both destination and origin are in the same region, the price is
$200. Add $100 to the price based on the difference between the two
regions. (for example, flying between adjacent regions (1,2 or 3,4 etc) will
cost $ 300. If the difference in region code is 2, then the price will be $400
and so on. [5]
5. At this point the customer can click on Modify or New Button. If the user clicks on
Modify Button, fill the Seats textbox, the new flight timing text box and the flight
number text box. The user can change the timing and/or seats and click on Save
button to modify the contents of the Schedule table. [4]
6. If the user clicks the New Flight Button, the user should be allowed to enter a
flight number, timing, and seats. The save button should update the schedule

Page 1

table. Please make sure that the fligh number is not duplicated or
destination/origin/timing is not duplicated. Show a message in the system
message area and allow the user to change their data. [4]
7. Use appropriate enabling and disabling of buttons. The cancel button clears all
selection and allows the user to choose a new combination of origin and
destination. [2].

Table Name
Airport
Schedule

I.

Attributes
AirportID Integer
AirportName String
AirportRegionCode - Integer
FlightNumber String
OriginID Integer (refer AirportID)
DestinationID - Integer (refer AirportID)
NumberSeatsAvailable - Integer
DepartureTime - Date/Time

Bonus[5] convert the program written for question 1 to a RMI based


application (with data access in the server)

Page 2

Anda mungkin juga menyukai