Package ejava.examples.txagent.blimpl
Class AgentSessionImpl
- java.lang.Object
-
- ejava.examples.txagent.blimpl.AgentSessionImpl
-
- All Implemented Interfaces:
AgentReservationSession
public class AgentSessionImpl extends Object implements AgentReservationSession
-
-
Field Summary
Fields Modifier and Type Field Description private Booking
booking
private BookingDAO
bookingDAO
private long
counter
private static org.slf4j.Logger
log
private HotelReservationSession
reservationist
-
Constructor Summary
Constructors Constructor Description AgentSessionImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addReservation(Person person, Date startDate, Date endDate)
void
cancelBooking()
void
close()
Booking
commit()
void
createBooking()
void
setBookingDAO(BookingDAO bookingDAO)
void
setReservationist(HotelReservationSession reservationist)
-
-
-
Field Detail
-
log
private static final org.slf4j.Logger log
-
booking
private Booking booking
-
bookingDAO
private BookingDAO bookingDAO
-
reservationist
private HotelReservationSession reservationist
-
counter
private long counter
-
-
Method Detail
-
createBooking
public void createBooking() throws AgentReservationException
- Specified by:
createBooking
in interfaceAgentReservationSession
- Throws:
AgentReservationException
-
addReservation
public void addReservation(Person person, Date startDate, Date endDate) throws AgentReservationException
- Specified by:
addReservation
in interfaceAgentReservationSession
- Throws:
AgentReservationException
-
cancelBooking
public void cancelBooking() throws AgentReservationException
- Specified by:
cancelBooking
in interfaceAgentReservationSession
- Throws:
AgentReservationException
-
commit
public Booking commit() throws AgentReservationException
- Specified by:
commit
in interfaceAgentReservationSession
- Throws:
AgentReservationException
-
close
public void close()
- Specified by:
close
in interfaceAgentReservationSession
-
setBookingDAO
public void setBookingDAO(BookingDAO bookingDAO)
-
setReservationist
public void setReservationist(HotelReservationSession reservationist)
-
-