Package br.com.caelum.vraptor.serialization

Examples of br.com.caelum.vraptor.serialization.Serializer.include()


  @Path("/orders/{order.id}")
  public void get(Order order) {
    order = database.getOrder(order.getId());
    if (order != null) {
      Serializer serializer = result.use(representation()).from(order);
      serializer.include("items").include("location");
      serializer.include("payment").serialize();
    } else {
      status.notFound();
    }
  }
View Full Code Here


  public void get(Order order) {
    order = database.getOrder(order.getId());
    if (order != null) {
      Serializer serializer = result.use(representation()).from(order);
      serializer.include("items").include("location");
      serializer.include("payment").serialize();
    } else {
      status.notFound();
    }
  }
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.