com.restfully.shop.services
Class ProductResourceBean

java.lang.Object
  extended by com.restfully.shop.services.ProductResourceBean
All Implemented Interfaces:
ProductResource

@Transactional
public class ProductResourceBean
extends Object
implements ProductResource


Constructor Summary
ProductResourceBean()
           
 
Method Summary
 Response createProduct(Product product, UriInfo uriInfo)
           
static void domain2entity(ProductEntity entity, Product product)
           
static Product entity2domain(ProductEntity entity)
           
 Product getProduct(int id)
           
 Products getProducts(int start, int size, String name, UriInfo uriInfo)
           
 void setEntityManager(javax.persistence.EntityManager em)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProductResourceBean

public ProductResourceBean()
Method Detail

setEntityManager

public void setEntityManager(javax.persistence.EntityManager em)

createProduct

public Response createProduct(Product product,
                              UriInfo uriInfo)
Specified by:
createProduct in interface ProductResource

domain2entity

public static void domain2entity(ProductEntity entity,
                                 Product product)

entity2domain

public static Product entity2domain(ProductEntity entity)

getProducts

public Products getProducts(int start,
                            int size,
                            String name,
                            UriInfo uriInfo)
Specified by:
getProducts in interface ProductResource

getProduct

public Product getProduct(int id)
Specified by:
getProduct in interface ProductResource


Copyright © 2011. All Rights Reserved.