Package org.springframework.samples.jpetstore.domain.logic

Examples of org.springframework.samples.jpetstore.domain.logic.PetStoreFacade


      Body msgBody = message.getBody();
      XStream xstream = new XStream(new DomDriver());
      xstream.alias("order", Order.class);
      Order order = (Order) xstream.fromXML((String) msgBody.get());

      PetStoreFacade petStore = (PetStoreFacade) getBeanFactory()
            .getBean("petStore");
      petStore.insertOrder(order);

      System.out.println("ORDER SUCCESSFULLY INSERTED\n");
      printOrderDetails(getOrderFromDB());

      return message;
View Full Code Here


      System.out.println("************************");
   }

   private Order getOrderFromDB() throws Exception
   {
      PetStoreFacade petStore = (PetStoreFacade) getBeanFactory()
            .getBean("petStore");
      System.out.println("QUERYING DATABASE FOR INSERTED ORDER");
      List<Order> orders = petStore.getOrdersByUsername("j2ee");
      return orders.get(orders.size() - 1);
   }
View Full Code Here

TOP

Related Classes of org.springframework.samples.jpetstore.domain.logic.PetStoreFacade

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.