66029ASSIGNMENT-1

2
ADVANCE JAVA PROGRAMMING B.TECH VI SEM – CSE A, CSE B, IT CSE 2604 & INE 2604 ASSI GNMENT-1 MM:07 Submission Date: 23.03.2015 Q1. Hotel SnowView Room Reservation System: Write a program to implement RMI client/server program. This program will be a room reservation system using RMI. You can assume that everybody is reserving the room for a specific period of time. In other words, our system does not give the guests the liberty to choose the dates for the reservation. In addition to this, there are 5 room types with different prices. _ We have 10 rooms of type 0 which are single rooms that costs 55 Euros a night _ We have 20 rooms of type 1 which are double rooms that costs 75 Euros a night _ We have 5 rooms of type 2 which are twin rooms that costs 80 Euros a night _ We have 3 rooms of type 3 which are triple rooms that costs 150 Euros a night _ We have 2 rooms of type 4 which are quad rooms that costs 230 Euros a night To implement this system you will have to write a server HotelReservationServer, a client HotelReservetionClient, a remote interface RoomReservationManager, and the implementation of the remote interface RoomReservationManagerImpl.

description

advance java

Transcript of 66029ASSIGNMENT-1

ADVANCE JAVA PROGRAMMINGB.TECH VI SEM CSE A, CSE B, IT CSE 2604 & INE 2604 ASSIGNMENT-1 MM:07 Submission Date: 23.03.2015

Q1. Hotel SnowView Room Reservation System: Write a program to implement RMI client/server program. This program will be a room reservation system using RMI. You can assume that everybody is reserving the room for a specific period of time. In other words, our system does not give the guests the liberty tochoose the dates for the reservation.In addition to this, there are 5 room types with different prices._ We have 10 rooms of type 0 which are single rooms that costs 55 Euros a night_ We have 20 rooms of type 1 which are double rooms that costs 75 Euros a night_ We have 5 rooms of type 2 which are twin rooms that costs 80 Euros a night_ We have 3 rooms of type 3 which are triple rooms that costs 150 Euros a night_ We have 2 rooms of type 4 which are quad rooms that costs 230 Euros a night

To implement this system you will have to write a server HotelReservationServer, a client HotelReservetionClient, a remote interface RoomReservationManager, and the implementation of the remote interface RoomReservationManagerImpl.

The output should look like the following: v rooms of type I are available for 55 Euros per nightw rooms of type II are available for 75 Euros per nightx rooms of type III are available for 80 Euros per nighty rooms of type IV are available for 150 Euros per nightz rooms of type V are available for 230 Euros per night The values of v, w, x, y, and z should be the current number of available rooms for eachtype of room.HotelReservationClient.java book : books a room of the specified type (if available), and registers the name of the guest.HotelReservationClient.java guests : list the names of all the registered guestsSo, for the list, book, and guests options the HotelReservationClient remotely invokes associated methods in a remote object. The HotelReservationClient gets the results of these remote method invocations back from the HotelReservationServer, and prints them out on its standard output. Implement this application using Java RMI for remote method calls, Java Swings for GUI Interface and JDBC for Java Database Connectivity.Note:- You can implement this application in JDK/ NetBeans IDE/ Eclipse IDE.