1.j2ee ����Դ��
2.什么是典源JBoss
3.ejbç¨åºä»£ç
j2ee ����Դ��
J2EE,JSP,Javaçåºå«JSP å°±æ¯ç¨æ¥åå¨æ页é¢çï¼å¯ä»¥å½å±å°J2EEç³»åä¸ã
Java è¿ä¸ªè¯çæ¦æ¬å¯è½æ´å¹¿ä¸äºï¼å 为Java å å« 3个é¢åï¼åå«æ¯ï¼
J2EE: ä¼ä¸çº§å¼å
J2MEï¼åµå ¥å¼å¼å
J2SEï¼å¾å½¢çé¢å¼å
javaå å«ä¸å¤§åæ¯:
J2SE --java standard edition--æ åçæ¬,è¿ä¸ªæ¯ä¸é¢ä¸¤ä¸ªçåºç¡!ä¸è¬æ¯ä½äºå®¢æ·ç«¯çåºç¨;
J2ME--java Micro edition --ä¸è¬ä½äºåµå ¥å¼åºç¨,ä¾å¦ææºæ¸¸æ
J2EE --java Enterprise Editon --ä¸è¬ä¸ºæå¡å¨ç«¯ç¨åºçåºç¨
JavaScript, è¿ä¸ªæ¯åµå ¥å¨ç½é¡µ(ä¸è¬ä¸ºhtml,ASP,JSPçç½é¡µ)çä¸ç§èæ¬è¯è¨,ç¨äºæ°æ®çéªè¯,æ¯æ页é¢çå¼çä¼ éçé®é¢çå¤ç;
JavaScriptè·javaä¸ç¹å ³ç³»é½æ²¡æ
javaæ¯ç¨åºè®¾è®¡è¯è¨(ä¸C/C++/C#åç±»)
JavaScriptæ¯ç½é¡µä¸çèæ¬è¯è¨(ä¸vbscriptçèæ¬è¯è¨åç±»)Javascriptæ¯ä¸ç§ç±Netscapeç
æ©å±èµæï¼
JavaScript çæ£å¼åç§°æ¯ "ECMAScript"ãè¿ä¸ªæ åç± ECMA ç»ç»åå±åç»´æ¤ãECMA- æ¯æ£å¼ç JavaScript æ åãè¿ä¸ªæ ååºäº JavaScript (Netscape) å JScript (Microsoft)ãNetscape (Navigator 2.0) ç Brendan Eich åæäºè¿é¨è¯è¨ï¼ä» å¹´å¼å§ï¼å·²ç»åºç°å¨ææç Netscape å Microsoft æµè§å¨ä¸ãECMA- çå¼åå§äº å¹´ï¼å¨ å¹´ 7 æï¼ECMA
ä¼å大ä¼é纳äºå®çé¦ä¸ªçæ¬ãJ2EE æææ¯ä¼ä¸çº§å¼åï¼æè°ä¼ä¸çº§å¼åï¼å°±æ¯å¨ä¼ä¸ä¸æç¨å°çä¸ç³»åJavaææ¯çæ»ç§°
什么是JBoss
是一个基于J2EE的开放源代码的应用服务器。 JBoss代码遵循LGPL许可,码j码可以在任何商业应用中免费使用。课设android 源码 下载JBoss是源代一个管理EJB的容器和服务器,支持EJB 1、典源贝塔测试源码1、码j码bingo游戏源码EJB 2、课设0和EJB3的源代规范。但JBoss核心服务不包括支持servlet/JSP的典源WEB容器,一般与Tomcat或Jetty绑定使用。码j码
课设ejbç¨åºä»£ç
课设EJBæ¯J2EEæ¡æ¶ä¸æéè¦çé¨åï¼ä¹æ¯ä¼ä¸åºç¨ä¸æ常ç¨çææ¯ä¹ä¸ï¼ç¶èEJBç客æ·ç«¯ç¼å对äºå¼åè èè¨ä¸æ¯ä¸ä»¶è½»æ¾çäºæ ãæ§ä»¶æ¶æä¸çEJBæ§ä»¶å¤§å¤§çç®åäºEJBèµæºçå¤ææ§ãé¾åº¦ï¼å¼åè åªéè¦éè¿ç®åçç»§æ¿ org.apache.beehive.controls.system.ejb.SessionEJBControlæè org.apache.beehive.controls.system.ejb.EntityEJBControlï¼ç¶åéè¿æä¾ç¸åºç注éå°±å¯ä»¥å®æ EJBèµæºç访é®ã
课设-------------------------------------------------------------
课设EJB Beanç±»æºä»£ç âHelloWorld.java
课设æ¸ å1 ejbsrcorgvivianjbeehivecontrolsexamplesejbhelloworld.java
课设1. package org.vivianj.beehive.controls.examples.ejb;
课设2.
课设3. import javax.ejb.*;
课设4.
课设5. public class HelloWorld
课设6. implements SessionBean
课设7. {
课设8. public void ejbCreate() {
课设9. }
课设. public String sayHello()
课设. {
课设. return âHello World!â;
课设. }
课设. }
课设å ±4页ã
课设EJB Remoteæ¥å£ç±»æºä»£ç âHelloWorldRemote.java
课设æ¸ å2 ejbsrcorgvivianjbeehivecontrolsexamplesejbHelloWorldRemote.java
课设1. package org.vivianj.beehive.controls.examples.ejb;
课设2.
课设3. import javax.ejb.EJBObject;
课设4. import java.rmi.RemoteException;
课设5.
课设6. import javax.ejb.*;
课设7.
课设8. public interface HelloWorldRemote extends EJBObject {
课设9.
课设. public String sayHello() throws RemoteException;
课设.
课设. }
课设EJB Homeæ¥å£ç±»æºä»£ç --HelloWorldHome.java
课设æ¸ å3 ejbsrcorgvivianjbeehivecontrolsexamplesejbHelloWorldHome.java
课设1. package org.vivianj.beehive.controls.examples.ejb;
课设2.
课设3. import javax.ejb.CreateException;
课设4. import javax.ejb.EJBHome;
课设5. import javax.ejb.FinderException;
课设6. import java.rmi.RemoteException;
课设7. import java.util.Collection;
课设8.
课设9. import javax.ejb.*;
课设.
课设. public interface HelloWorldHome extends EJBHome {
课设.
课设. public HelloWorldRemote create()
课设. throws CreateExceptionï¼ RemoteException;
课设.
课设. }
课设EJBå¼åå®æåï¼æ们å¯ä»¥å°EJBæå æä¼ä¸åºç¨ï¼ç¶åå°çæçä¼ä¸åºç¨åå¸å°JBossåºç¨æå¡å¨ä¸ã
课设å¼åEJBæ§ä»¶
课设æ们ç°å¨æ¥å¼åä¸ä¸ªEJBæ§ä»¶-- HelloWorldSessionEJBControlï¼éè¿å®æ们è½å¤ç´æ¥è®¿é® 1.å¼åSessionBean ä¸å¼ååé¨ç½²çEJBã
课设HelloWorldSessionEJBControléè¿JBossæä¾çorg.jnp.interfaces.NamingContextFactoryå·¥åç±»è·åEJB访é®çä¸ä¸æç¯å¢ã
课设æ¸ å4ä¸æ¯EJBæ§ä»¶çå ¨é¨æºä»£ç ã
课设æ¸ å4 srcorgvivianjbeehivecontrolsexamplescontrols
课设HelloWorldSessionEJBControl.java
课设1. package org.vivianj.beehive.controls.examples.controls;
课设2.
课设3. import org.apache.beehive.controls.api.bean.ControlExtension;
课设4. import org.apache.beehive.controls.system.ejb.SessionEJBControl;
课设5. import org.vivianj.beehive.controls.examples.ejb.helloworldHome;
课设6. import org.vivianj.beehive.controls.examples.ejb.helloworldRemote;
课设7.
课设8. /
课设**9. * HelloWorldSessionEJBControl ç¨äºå°è£ 访é®è¿ç¨JBossæå¡å¨ä¸
课设. * SessionBeançæä½æ¹æ³
课设. */
课设. @ControlExtension
课设. @SessionEJBControl.EJBHome(jndiName = âjndi/helloworldâ)
课设. @SessionEJBControl.JNDIContextEnv(
课设. contextFactory = âorg.jnp.interfaces.NamingContextFactoryâï¼
课设. providerURL = âjnp://localhost:â)
课设. public interface HelloWorldSessionEJBControl
课设. extends SessionEJBControlï¼
课设. HelloWorldHomeï¼ HelloWorldRemote {
课设. }
课设