Topic: 用javac编译EJB中的home接口,出现错误.. |
Print this page |
1.用javac编译EJB中的home接口,出现错误.. | Copy to clipboard |
Posted by: momocha Posted on: 2003-07-07 15:03 前两天在贵站上看了一教程,但用javac编译home接口的时侯,出现错误,请指点..我把weblogic.jar加到了classpath中了.... 1.远程接口 package examples; import javax.ejb.*; import java.rmi.RemoteException; public interface Product extends EJBObject { public String getName() throws RemoteException; public void setName(String name) throws RemoteException; public String getDescription() throws RemoteException; public void setDescription(String description) throws RemoteException; public double getBasePrice() throws RemoteException; public void setBasePrice(double price) throws RemoteException; public String getProductID() throws RemoteException; } 2.Home接口 package examples; import javax.ejb.*; import java.rmi.RemoteException; import java.util.Collection; public interface ProductHome extends EJBHome { Product create(String productID, String name, String description, double basePrice) throws CreateException, RemoteException; public Product findByPrimaryKey(String key) throws FinderException, RemoteException; public Collection findByName(String name) throws FinderException, RemoteException; public Collection findByDescription(String description) throws FinderException, RemoteException; public Collection findByBasePrice(double basePrice) throws FinderException, RemoteException; public Collection findExpensiveProducts(double minPrice) throws FinderException, RemoteException; public Collection findCheapProducts(double maxPrice) throws FinderException, RemoteException; public Collection findAllProducts() throws FinderException, RemoteException; } 用 javac -d . ProductHome.java提示如下错误.. ProductHome.java:7: cannot resolve symbol symbol : class Product location: interface examples.ProductHome Product create(String productID, String name, String description, double basePrice) throws CreateException, RemoteException; ^ ProductHome.java:8: cannot resolve symbol symbol : class Product location: interface examples.ProductHome public Product findByPrimaryKey(String key) throws FinderException, Remo teException; ^ 2 errors 我用javac -classpath c:\1\src\examples ProductHome.java其中c:\1\src\examples是远程接口的class目录...出现更多的错误..... |
2.Re:用javac编译EJB中的home接口,出现错误.. [Re: momocha] | Copy to clipboard |
Posted by: mengzhihai Posted on: 2003-07-08 12:32 没人回答我....5555 |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |