当前位置: 技术问答>java相关
初级问题,JAVA编译EJB不成功,不知道是不是path之类的问题,错误如下
来源: 互联网 发布时间:2017-03-24
本文导语: E:>cd helloworld E:HelloWorld>javac *.java Hello.java:2: cannot resolve symbol symbol : class EJBObject location: interface examples.Hello public interface Hello extends EJBObject{ ^ HelloBean.java:3: cann...
E:>cd helloworld
E:HelloWorld>javac *.java
Hello.java:2: cannot resolve symbol
symbol : class EJBObject
location: interface examples.Hello
public interface Hello extends EJBObject{
^
HelloBean.java:3: cannot resolve symbol
symbol : class SessionContext
location: class examples.HelloBean
private SessionContext ctx;
^
HelloLocalHome.java:3: package java.ejb does not exist
HelloLocal create() throws java.ejb.CreateException;
^
3 errors
E:HelloWorld>javac *.java
Hello.java:2: cannot resolve symbol
symbol : class EJBObject
location: interface examples.Hello
public interface Hello extends EJBObject{
^
HelloBean.java:3: cannot resolve symbol
symbol : class SessionContext
location: class examples.HelloBean
private SessionContext ctx;
^
HelloLocalHome.java:3: package java.ejb does not exist
HelloLocal create() throws java.ejb.CreateException;
^
3 errors
|
下载j2ee,classpath添加j2ee.jar