开发者

What is the best way to reuse classes from another Java project in Eclipse?

开发者 https://www.devze.com 2023-01-01 19:45 出处:网络
I have multiple Java projects in Eclipse. I would like to reuse some classes in my new project from my old project. What is the best way to do that in Eclipse?

I have multiple Java projects in Eclipse. I would like to reuse some classes in my new project from my old project. What is the best way to do that in Eclipse?

I.e. is it possible to add another "project folder" to the build-path for my new proje开发者_如何学Cct?


Yes, in the build path dialog (Build Path > Configure Build Path...), go to the Projects tab, and add the project dependencies.

On the included project, you can use the Order and Export tab to select, which parts of your source folders and libraries to export to dependent projects.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号