com.elasticpath.cmweb.ajaxservice
Interface CatalogAjaxService

All Superinterfaces:
EpService
All Known Implementing Classes:
CatalogAjaxServiceImpl

public interface CatalogAjaxService
extends EpService

This service provides access to functionality and data (beans) for manipulating catalog objects on the Javascript client Catalog page.


Method Summary
 void deleteProductAssociation(long productUidPk, long productAssociationUidPk)
          Removes a product association from a product.
 java.util.List findByCategoryUidMinimal(long categoryUid)
          Returns a list of ProductInfoAjaxBean carries basics info of the products based on the given category Uid.
 java.util.List findByCategoryUidMinimalPaginated(long categoryUid, int startIndex, int numProducts)
          Returns a list of ProductInfoAjaxBeans that carry basic info about the products based on the given category Uid.
 java.util.List findCategoryInfoByCriteria(CategorySearchCriteria categorySearchCriteria)
          Retrieve the list of categories, whose specified property contain the given criteria value.
 java.util.List findProducSkuAjaxBeanByProductUid(long productUid)
          Returns a list of ProductSkuAjaxBeans based on the given product Uid.
 java.util.List findProductInfoByCriteria(ProductSearchCriteria productSearchCriteria)
          Retrieve the list of ProductInfoAjaxBean carries basics info of the products matching the given criteria value.
 CategoryAjaxBean getCategoryAjaxBean(long uidPk)
          Get a bean containing a domain layer product object as well as other data needed for display on the Javascript UI.
 int getNumProductsInCategory(long categoryUid)
          Returns the number of products in the given category.
 ProductAjaxBean getProductAjaxBean(long uidPk)
          Get a bean containing a domain layer product object as well as other data needed for display on the Javascript UI.
 ProductSkuAjaxBean getProductSkuAjaxBean(long uidPk)
          Get a bean containing data needed for displaying a product sku on the Javascript UI.
 void setProductService(ProductService productService)
          Set the product service used to retrieve product information.
 void swapProductAssociationOrder(long productUidPk, long association1UidPk, long association2UidPk)
          Re-orders two product associations of the given product.
 
Methods inherited from interface com.elasticpath.service.EpService
getElasticPath, setElasticPath
 

Method Detail

deleteProductAssociation

void deleteProductAssociation(long productUidPk,
                              long productAssociationUidPk)
Removes a product association from a product.

Parameters:
productUidPk - The UID of the product whose association is to be removed
productAssociationUidPk - the UID of the ProductAssociation to be removed

findByCategoryUidMinimal

java.util.List findByCategoryUidMinimal(long categoryUid)
Returns a list of ProductInfoAjaxBean carries basics info of the products based on the given category Uid.

Parameters:
categoryUid - the category Uid
Returns:
a list of product info

findByCategoryUidMinimalPaginated

java.util.List findByCategoryUidMinimalPaginated(long categoryUid,
                                                 int startIndex,
                                                 int numProducts)
Returns a list of ProductInfoAjaxBeans that carry basic info about the products based on the given category Uid.

Parameters:
categoryUid - the category Uid
startIndex - the starting index of the first product to be returned
numProducts - the number of products to be returned, starting from the start index
Returns:
a list of product info

findCategoryInfoByCriteria

java.util.List findCategoryInfoByCriteria(CategorySearchCriteria categorySearchCriteria)
Retrieve the list of categories, whose specified property contain the given criteria value.

Parameters:
categorySearchCriteria - the categorySearchCriteria to search on.
Returns:
list of categories matching the given criteria.

findProducSkuAjaxBeanByProductUid

java.util.List findProducSkuAjaxBeanByProductUid(long productUid)
Returns a list of ProductSkuAjaxBeans based on the given product Uid.

Parameters:
productUid - the product Uid
Returns:
a list of ProductSkuAjaxBean

findProductInfoByCriteria

java.util.List findProductInfoByCriteria(ProductSearchCriteria productSearchCriteria)
Retrieve the list of ProductInfoAjaxBean carries basics info of the products matching the given criteria value.

Parameters:
productSearchCriteria - the productSearchCriteria to search on.
Returns:
the list of ProductInfoAjaxBean carries basics info of the products.

getCategoryAjaxBean

CategoryAjaxBean getCategoryAjaxBean(long uidPk)
Get a bean containing a domain layer product object as well as other data needed for display on the Javascript UI.

Parameters:
uidPk - the unique identifier for the product to be returned in the bean
Returns:
the ProductAjaxBean

getNumProductsInCategory

int getNumProductsInCategory(long categoryUid)
Returns the number of products in the given category.

Parameters:
categoryUid - The UID of the category whose number of products is to be returned.
Returns:
the number of products in the category

getProductAjaxBean

ProductAjaxBean getProductAjaxBean(long uidPk)
Get a bean containing a domain layer product object as well as other data needed for display on the Javascript UI.

Parameters:
uidPk - the unique identifier for the product to be returned in the bean
Returns:
the ProductAjaxBean

getProductSkuAjaxBean

ProductSkuAjaxBean getProductSkuAjaxBean(long uidPk)
Get a bean containing data needed for displaying a product sku on the Javascript UI.

Parameters:
uidPk - the unique identifier for the product to load data for
Returns:
the ProductSkuAjaxBean

setProductService

void setProductService(ProductService productService)
Set the product service used to retrieve product information.

Parameters:
productService - the ProductService

swapProductAssociationOrder

void swapProductAssociationOrder(long productUidPk,
                                 long association1UidPk,
                                 long association2UidPk)
Re-orders two product associations of the given product. Note: Persists the ordering change but does not re-order the collection in the product parameter

Parameters:
productUidPk - the UID of the product whose associations are to be reordered
association1UidPk - the uid of one of the first product association that will take the position of the second
association2UidPk - the uid of the second product association that will take the position of the first