public class JPAReservationDAO extends Object implements ReservationDAO
| Modifier and Type | Field and Description |
|---|---|
private EntityManager |
em |
private org.apache.commons.logging.Log |
log |
| Constructor and Description |
|---|
JPAReservationDAO() |
| Modifier and Type | Method and Description |
|---|---|
Reservation |
createReservation(Reservation reservation) |
Reservation |
getReservation(long id) |
Reservation |
getReservationByConfirmation(String confirmation) |
List<Reservation> |
getReservations(int index,
int count) |
List<Reservation> |
getReservations(String queryName,
Map<String,Object> params,
int index,
int count) |
Reservation |
removeReservation(Reservation reservation) |
void |
setEntityManager(EntityManager em) |
Reservation |
updateReservation(Reservation reservation) |
private org.apache.commons.logging.Log log
private EntityManager em
public void setEntityManager(EntityManager em)
public Reservation createReservation(Reservation reservation) throws DAOException
createReservation in interface ReservationDAODAOExceptionpublic Reservation getReservation(long id) throws DAOException
getReservation in interface ReservationDAODAOExceptionpublic List<Reservation> getReservations(int index, int count) throws DAOException
getReservations in interface ReservationDAODAOExceptionpublic List<Reservation> getReservations(String queryName, Map<String,Object> params, int index, int count) throws DAOException
getReservations in interface ReservationDAODAOExceptionpublic Reservation removeReservation(Reservation reservation) throws DAOException
removeReservation in interface ReservationDAODAOExceptionpublic Reservation updateReservation(Reservation reservation) throws DAOException
updateReservation in interface ReservationDAODAOExceptionpublic Reservation getReservationByConfirmation(String confirmation) throws DAOException
getReservationByConfirmation in interface ReservationDAODAOExceptionCopyright © 2015 John's Hopkins University, Engineering Programs for Professionals. All rights reserved.