《高级Web技术》参考资料:3-应用web_4-EJB_EJB开发-4-创建Session EJB

高级Meb技术 Java 2 Enterprise Edition
高级Web技术 Java 2 Enterprise Edition

本次课程内容 创建 Remote Interface 创建 Home Interface ■创建 Enterprise Bean Class
本次课程内容 ◼ 创建 Remote Interface ◼ 创建 Home Interface ◼ 创建 Enterprise Bean Class

Create Remote Interface
Create Remote Interface

Remote接口 InterfacE Remote interface enterprise bean通过商业方法执行特定的任务 enterprise bean的商业方法不能被客户应用直接访问 Remote interface包含 enterprise bean实现的商业方法的定义 客户程序只能通过 remote interface访问 enterprise bean实现的商 业方法,不能直接调用
Remote接口 ◼ Remote Interface ◼ enterprise bean通过商业方法执行特定的任务 ◼ enterprise bean的商业方法不能被客户应用直接访问 ◼ Remote Interface包含enterprise bean实现的商业方法的定义 ◼ 客户程序只能通过remote interface访问enterprise bean实现的商 业方法,不能直接调用

相关角色 Remote接口由 Enterprise Bean Provider编写 ■EJB容器生成 Remote接口的实现 EJB Container Enterprise Bean Provider
相关角色 ◼ Remote接口由Enterprise Bean Provider编写 ◼ EJB容器生成Remote接口的实现

Remote接口定义 //The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb. ki import java rmi.* public interface Hello extends EJBObject String sayHello(string MyName) throws RemoteException; 构建一个名为 HelloApp的J2EE应用,上图给出了 该应用所使用的 remote接口的定义 该应用中的 Enterprise bean只有一个商业方法 sayhello Remote接口Helo的定义中包含了 say Hello方法的定义
Remote接口定义 ◼ 构建一个名为HelloApp的J2EE应用,上图给出了 该应用所使用的remote接口的定义 ◼ 该应用中的Enterprise bean只有一个商业方法—— sayHello ◼ Remote接口Hello的定义中包含了sayHello方法的定义 //The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb.*; import java.rmi.*; public interface Hello extends EJBObject { String sayHello(String MyName) throws RemoteException; }

import //used by the HelloApp application ote interface of an enterprise bean /The code is used to create the re import javax. ejb mport java rmi. F public interface Hello extends EJBobject { String sayHello(string MyName) throws Remote Exception import语句用来包含预定义的类 s Java.rm包使用java前缀,因为rm包是标准的Java2 SDK包 javax ejb包不是标准的Java2SDK包,是Java扩展 ( extension)包,Java扩展包并不包含在Java核心库中
//The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb.*; import java.rmi.*; public interface Hello extends EJBObject { String sayHello(String MyName) throws RemoteException; } import ◼ import语句用来包含预定义的类 ◼ java.rmi包使用java前缀,因为rmi包是标准的Java 2 SDK包 ◼ javax.ejb包不是标准的Java 2 SDK包,是Java扩展 (extension)包,Java扩展包并不包含在Java核心库中

接口定义 //used by the HelloApp applicatiop ote interface of an enterprise bean /The code is used to create the re import javax.ejb. i import java rmi. i public interface Hello extends eJBobject String sayhello(string MyName) throws RemoteException; 本例中定义了一个名为Helo的 remote接口,该接口被定义为 public 接口以允许其它构件访问
//The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb.*; import java.rmi.*; public interface Hello extends EJBObject { String sayHello(String MyName) throws RemoteException; } 接口定义 ◼ 本例中定义了一个名为Hello的remote接口,该接口被定义为public 接口以允许其它构件访问

接口继承性 /The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb. import java rmi K, public interface Hello extends EJBObject String sayHello(string MyName) throws Remote Exception He|l接口继承了 EJBObject接口 EJBObject接口包含在 javax. ejb包中,它又继承了 java rmi Remote接口
接口继承性 //The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb.*; import java.rmi.*; public interface Hello extends EJBObject { String sayHello(String MyName) throws RemoteException; } ◼ Hello接口继承了EJBObject接口 ◼ EJBObject接口包含在javax.ejb包中,它又继承了 java.rmi.Remote接口

方法定义 //used by the HelloApp application ote interface of an enterprise bean /The code is used to create the re import javax.ejb. import java rmi K, public interface Hello extends EJBObject String sayHello(String MyName)throws RemoteExdeption; Remote接口用来定义 enterprise bean的商业方 n本例中仅包含一个商业方法的定义— say Hello
方法定义 //The code is used to create the remote interface of an enterprise bean //used by the HelloApp application import javax.ejb.*; import java.rmi.*; public interface Hello extends EJBObject { String sayHello(String MyName) throws RemoteException; } ◼ Remote接口用来定义enterprise bean的商业方 ◼ 本例中仅包含一个商业方法的定义——sayHello
按次数下载不扣除下载券;
注册用户24小时内重复下载只扣除一次;
顺序:VIP每日次数-->可用次数-->下载券;
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB基础-3-主要接口设计原则.ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB基础-2-体系结构.ppt
- 《高级Web技术》参考资料:3-WS与工作流_4-Service web_BPELOverview.pdf
- 《高级Web技术》参考资料:2-Web上的数据标准-XML_XML基础—概述与语法.pdf
- 《高级Web技术》参考资料:2-soap&wsdl&uddi_4-Service web_WSDL.ppt
- 《高级Web技术》参考资料:2-soap&wsdl&uddi_4-Service web_UDDI.ppt
- 《高级Web技术》参考资料:2-soap&wsdl&uddi_4-Service web_Tomcat与SOAP&AXIS集成.ppt
- 《高级Web技术》参考资料:2-soap&wsdl&uddi_4-Service web_SOAP.ppt
- 《高级Web技术》参考资料:1-webapp outline_雅蛙网站的使用体验及对WEB2.0的认识.doc
- 《高级Web技术》参考资料:1-webapp outline_离线Web技术在医疗业务应用的设想与尝试.docx
- 《高级Web技术》参考资料:1-webapp outline_拥抱Web3.0.pdf
- 《高级Web技术》参考资料:1-webapp outline_what is web2.0.docx
- 《高级Web技术》参考资料:1-webapp outline_web app outline Web 技术概述.ppt
- 《高级Web技术》参考资料:1-webapp outline_web app outline Web 技术概述.pdf
- 《高级Web技术》参考资料:1-webapp outline_Planetary-Scale Views on a Large Instant-Messaging Network.pdf
- 《高级Web技术》参考资料:1-SOA和WS概述_4-Service web_Web Service概述及其应用.ppt
- 《高级Web技术》参考资料:1-SOA和WS概述_4-Service web_面向服务体系架构概述 SOA Introduction.ppt
- 厦门大学:《大数据技术原理与应用》课程教学资源(PPT课件讲稿)第八章 流计算(2016年春季学期授课版本).ppt
- 厦门大学:《大数据技术原理与应用》课程教学资源(PPT课件讲稿)第七章 MapReduce(2016年春季学期).ppt
- 厦门大学:《大数据处理技术 Spark》课程讲义(PPT教学课件)第1章 大数据技术概述(2017年春季学期).ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB开发-5-编写Entity Bean.ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB开发-6-创建客户程序.ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB开发-7-部署EJB应用.ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB高级-10-安全性控制..ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB高级-11-EJB3..ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB高级-8-资源管理与EJB环境.ppt
- 《高级Web技术》参考资料:3-应用web_4-EJB_EJB高级-9-事务处理.ppt
- 《高级Web技术》参考资料:应用web - EJB 3RD EDITION - Richard Monson-Haefel.pdf
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_Hibernate-课件.ppt
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_J2EE模式与框架struts(2).ppt
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_Spring Introduction.ppt
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_ajax.ppt
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_Ajax介绍.ppt
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_DWR_ch03.pdf
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_DWR_ch05.pdf
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_materials_ajax first essay.doc
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_materials_Ajax in action中文版.doc
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_materials_AJAXBasics.pdf
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_materials_AJAXBasics_speakernoted.pdf
- 《高级Web技术》参考资料:3-应用web_5-J2EE框架_阅读参考资料_ajax+J2EE_materials_GWT.pdf