import javax.jws.WebMethod; import javax.jws.WebParam; import javax.jws.WebService; @WebService(serviceName = "Reservation") public class Reservation { public int numberOfSeats; public PersistentInterval timetable; public PersistentReservationData reservationData; public Reservation() { // ... } @WebMethod(operationName = "getTimeTable") public ArrayList getTimeTable() { return persistentInterval2IntervalArrayList(timetable); } @WebMethod(operationName = "getAvailableSeats") public int getAvailableSeats(@WebParam(name = "interval") Interval interval) { int result = numberOfSeats; // ... return result; } @WebMethod(operationName = "makeReservation") public boolean makeReservation( @WebParam(name = "customerId") int customerId, @WebParam(name = "interval") Interval interval, @WebParam(name = "noOfSeatsRequired") int noOfSeatsRequired) { boolean result = false; // ... return result; } @WebMethod(operationName = "cancelReservation") public boolean cancelReservation( @WebParam(name = "customerId") int customerId, @WebParam(name = "interval") Interval interval) { boolean result = false; // ... return result; } }