customerrule.java

来自「一个基于java工厂模式的 的实现」· Java 代码 · 共 58 行

JAVA
58
字号
/*
 * CustomerRule.java
 *
 * Created on 2007年4月18日, 下午2:48
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package com.ebuy.businessrule;

import com.ebuy.common.dao.IDAO;
import com.ebuy.common.dao.IDAOFactory;
import com.ebuy.common.rule.IRule;
import com.ebuy.common.NameProvider;
import com.ebuy.entities.CustomerEntity;
import java.util.List;

/**
 *
 * @author Administrator
 */
public class CustomerRule extends RuleAdapter
{
    
    /** Creates a new instance of CustomerRule */
    public CustomerRule()
    {
        super(NameProvider.Customer);
    }

    public boolean addEntity(Object entity)
    {
       return dao.addEntity(entity);
    }

    public boolean updateEntity(Object entity)
    {
        return false;
    }

    public boolean deleteEntity(Object entity)
    {
         return false;
    }

    public Object findByPK(Object... pk)
    {
       return this.dao.findByPK(pk);
    }

    public List findAll()
    {
        return null;
    }
    
}

⌨️ 快捷键说明

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