A brief intermission
Before we get into the SOAP web service implementation, we need to complement the applications to execute a seat query using the existing REST web service and display the results on the query page. Once this is done, we can pick up from there and develop our SOAP service. So, to get this done, follow these steps:
Open
ExhibitionBean
of the Theater project, add a method that will receive the exhibition ID chosen by the user, and return a list of seat types that are linked to that specific exhibition:@GET @Path("{id}/seats") @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON }) public List<Seat> getSeatsByExhibition( @PathParam("id") int id) { String jpql = "SELECT s FROM Seat s, Exhibition e " + "WHERE (s.room.id = e.room.id) " + "AND (e.id = ?1)"; if (id != 0) { Query query = em.createQuery(jpql); query.setParameter(1, id); @SuppressWarnings("unchecked") List<Seat...