在Java中包含一个新包 [英] including a new package in java
本文介绍了在Java中包含一个新包的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要在Java中包含一个新软件包
i need to include a new package in java
com.plumtree.openfoundation.security
我无法包含这个特定的包裹.
参考链接:
http://docs.oracle.com/cd/E23010_01/doc.1034/.../package-summary.html [
i am unable to include this particular package.
reference link:
http://docs.oracle.com/cd/E23010_01/doc.1034/.../package-summary.html[^]
How to include this package in my project file
推荐答案
首先,您不包括该包,而是包括一个包中的类.您可以使用通配符,因此例如可以使用以下内容:
Firstly you don not include the package, but classes from a package. You can use the wildcard, so for example something like this will work:
import com.plumtree.openfoundation.security.IXPCrypto; // import the single class
import com.plumtree.openfoundation.security.*; // import the entire package
您还需要将jar文件放在您的库路径中.
理查德很聪明,它是import
而不是include
;星期一晨起疯狂的不幸案例.
You also need to have the jar file in your library path.
Richard is clever, it''s import
not include
; a sad case of Monday Morning Madness.
这篇关于在Java中包含一个新包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文