productmanagerimpl.java

来自「STRUTS数据库项目开发宝典」· Java 代码 · 共 49 行

JAVA
49
字号
package com.relationinfo.service.impl;import java.util.List;import com.relationinfo.model.Product;import com.relationinfo.dao.ProductDAO;import com.relationinfo.service.ProductManager;public class ProductManagerImpl extends BaseManager implements ProductManager {    private ProductDAO dao;    /**     * Set the DAO for communication with the data layer.     * @param dao     */    public void setProductDAO(ProductDAO dao) {        this.dao = dao;    }    /**     * @see com.relationinfo.service.ProductManager#getProducts(com.relationinfo.model.Product)     */    public List getProducts(final Product product) {        return dao.getProducts(product);    }    /**     * @see com.relationinfo.service.ProductManager#getProduct(String productid)     */    public Product getProduct(final String productid) {        return dao.getProduct(new String(productid));    }    /**     * @see com.relationinfo.service.ProductManager#saveProduct(Product product)     */    public void saveProduct(Product product) {        dao.saveProduct(product);    }    /**     * @see com.relationinfo.service.ProductManager#removeProduct(String productid)     */    public void removeProduct(final String productid) {        dao.removeProduct(new String(productid));    }}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?