在Eclipse中构建另一个项目在Eclipse中使用的jar的项目 [英] Project in Eclipse that builds a jar used by another project in Eclipse

查看:150
本文介绍了在Eclipse中构建另一个项目在Eclipse中使用的jar的项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有几个项目在Eclipse中打开。其中一个是主要的应用程序,其他的是构建该主应用程序使用的jar。当我在主应用程序中打F3的方法调用时,如何让它进入另一个项目的源代码,而不是把我带到库列表中的类文件?我得到它,以便它显示我的来源,但如果我去另一个项目,我不能实际编辑它,类似地,当我在调试器中通过它不会进入可编辑的代码。 / p>

我不知道它是否相关,但是我们使用Maven来处理依赖。



我知道这应该很简单,但是我没有找到这个选项。

解决方案

而不是将其他项目的jar包含在在其库路径上的主应用程序,将项目选项卡中的项目作为依赖关系包含在项目属性对话框中。


I have several projects open in Eclipse. One of them is the main app, and others build jars used by that main app. How do I make it so that when I hit F3 on a method call in the main app that it takes me to the source in the other project instead of taking me to the class file in the Libraries list? I got it so that it shows me the source, but I can't actually edit it like it could if I go to the other project, and similarly when I step through in the debugger it doesn't go into the editable code.

I don't know if it's relevant, but we're using Maven to handle the dependencies.

I know this should be simple, but I haven't found the option.

解决方案

Instead of including the other projects' jars in the main app on its library path, include the projects as dependencies in the "Projects" tab inside the Project Properties dialog.

这篇关于在Eclipse中构建另一个项目在Eclipse中使用的jar的项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆