Package com.theoryinpractise.halbuilder.api

Examples of com.theoryinpractise.halbuilder.api.Representation


    // Persist the updated item
    persistentItem = itemReadService.saveOrUpdate(item.get());

    // Provide a representation to the client
    Representation representation = new AdminItemRepresentation().get(persistentItem);

    return ok(representation);

  }
View Full Code Here


    // Persist the updated delivery
    delivery = deliveryReadService.saveOrUpdate(delivery);

    // Provide a representation to the client
    Representation representation = new SupplierDeliveryRepresentation().get(delivery);

    return ok(representation);

  }
View Full Code Here

  public Representation get(PaginatedList<User> users, Optional<User> principal) {

    Preconditions.checkNotNull(users, "users");

    URI self = UriBuilder.fromPath("/admin/user").build();
    Representation userList = Representations.newPaginatedList(self, users);

    for (User user : users.list()) {
      Representation userRepresentation = customerUserRepresentation.get(user, principal);

      // TODO Fill this in for all admin fields
      //userRepresentation.withProperty("id", user.getId())
      // End of build
      ;
View Full Code Here

TOP

Related Classes of com.theoryinpractise.halbuilder.api.Representation

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.