简体   繁体   English

Eclipse在使用“添加JAR”时找不到某些库,在使用“添加外部JAR”时找到了它们。

[英]Eclipse doesn't find some libraries when using “Add JARs”, does find them if using “Add external JARs”

I'm trying to add some libraries to my Java project. 我正在尝试向我的Java项目中添加一些库。 My IDE is Eclipse. 我的IDE是Eclipse。 Visiting 来访

Project Properties -> Java Build Path -> Libraries 项目属性-> Java构建路径->库

enables me to add libraries to my project. 使我可以向我的项目添加库。 If I'm using Add External JARs , I can find all of my libraries (screenshot below). 如果我使用“ Add External JARs ,则可以找到我的所有库(下面的屏幕截图)。

在此处输入图片说明

However, if I'm trying to do the same while using Add JARs , I get a completely different screen ( the library listed isn't even there! ): 但是,如果我尝试在使用Add JARs执行相同的操作,则会得到一个完全不同的屏幕( 列出的库甚至不存在! ):

在此处输入图片说明

I'm 100% sure that I'm browsing the correct directories. 我100%确保我在浏览正确的目录。 It seems like there's a cache problem with Eclipse or something like that. 似乎Eclipse或类似的东西存在缓存问题。

I'm appreciating all suggestions on how to solve this problem. 我很欣赏有关如何解决此问题的所有建议。 Perhaps a workspace-wide settings reset might be in place? 也许在工作区范围内重置了设置?

使用“ Add Jars选项,您可以添加present workspacepresent workspace所有罐子。使用“ Add External Jars您可以从file system添加罐子。

'Add Jar' -> Adds the source of a jar from your workspace '添加罐子->从工作区添加罐子的源

'Add External jar' -> Adds an external .jar or .zip file (something that is not found in your workspace) “添加外部jar”->添加外部.jar或.zip文件(在您的工作空间中找不到的文件)

'Add Library' -> Adds installed libraries found on your system or in Eclipse '添加库'->添加在系统或Eclipse中找到的已安装库

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM