catalogservice.java
来自「这是一些关于JSF实例的源代码,很难得的,对学习Web页面编程很有帮助」· Java 代码 · 共 78 行
JAVA
78 行
/*
* JCatalog Project
*/
package catalog.model.service;
import java.util.List;
//
import catalog.model.businessobject.Product;
import catalog.model.businessobject.Category;
import catalog.model.exception.CatalogException;
/**
* The catalog business service interface.
* <p>
* This class contains catalog management related businss logic.
*
* @author <a href="mailto:derek_shen@hotmail.com">Derek Y. Shen</a>
*/
public interface CatalogService {
/**
* Save the product.
*
* @param product the product to be saved
* @return the product saved
* @throws CatalogException
*/
public Product saveProduct(Product product) throws CatalogException;
/**
* Update product.
*
* @param product the product to be updated
* @throws CatalogException
*/
public void updateProduct(Product product) throws CatalogException;
/**
* Delete product.
*
* @param product the product to be deleted
* @throws CatalogException
*/
public void deleteProduct(Product product) throws CatalogException;
/**
* Get product by product id.
* @param productId the product id
* @return the product associated with the product id
* @throws CatalogException
*/
public Product getProduct(String productId) throws CatalogException;
/**
* Get category by id.
*
* @param categoryId the category id
* @return the category associated with the category id
* @throws CatalogException
*/
public Category getCategory(String categoryId) throws CatalogException;
/**
* Get all products.
*
* @return a list with all products
* @throws CatalogException
*/
public List getAllProducts() throws CatalogException;
/**
* Get all categories.
*
* @return a list with all categories
* @throws CatalogException
*/
public List getAllCategories() throws CatalogException;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?