teacherhome.java

来自「精通java核心技术》随书源代码」· Java 代码 · 共 31 行

JAVA
31
字号
// ==================== Program Discription ==========================
//   程序名称:示例18-13 : TeacherHome.java
//   程序目的:实体Bean Home 接口
// ==============================================================

import java.rmi.RemoteException;
import javax.ejb.*;

public interface TeacherHome extends EJBHome
{
    
    /**
     * @J2EE_METHOD  --  findByPrimaryKey
     * Called by the client to find an EJB bean instance, usually find by primary key.
     * @throws java.rmi.RemoteException
     * @throws javax.ejb.FinderException
     */
    public Teacher findByPrimaryKey    ( String primaryKey) 
                throws RemoteException, FinderException;
    
    /**
     * @J2EE_METHOD  --  create
     * Called by the client to create an EJB bean instance. It requires a matching pair in
     * the bean class, i.e. ejbCreate().
     * @throws java.rmi.RemoteException
     * @throws javax.ejb.CreateException
     */
    public Teacher create    (String id) 
                throws RemoteException, CreateException;
   public java.util.Collection findAll()throws RemoteException, FinderException;
   public java.util.Collection findByDegree(String degree)throws RemoteException, FinderException;
   public java.util.Collection findStudentsByTeacher(String teacherId)throws RemoteException, FinderException;
}

⌨️ 快捷键说明

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