Reputation: 64391
(This may be a dumb question but I am not quite familiar with the interesting eclipse importing logic)
I am trying to read the source code of Netty, so I checkout the tag
folder for Netty-4.0.24.Final from the Netty SVN (https://github.com/netty/netty).
The files are shown as below:
Since there's a pom.xml
files there, I use the "import existing maven project" to import it into Eclipse.
But the imported result looks like this:
I am expecting some well-formatted package layout. What's wrong?
I found this thread: "Source folder is not a Java project" error in eclipse
It seems I need to manually turn on the Java Project Facet for each project in order to see source code organized in packages. But I am wondering does it have to be this tedious? Is there any simpler way to import a maven project and display it in packages?
Upvotes: 1
Views: 602
Reputation: 24581
It doesn't matter if you are using tag or latest branch, Netty project composed from a sub-projects you see in the worskpace
Yes each one is full Maven project on it's own and gets deployed as separate artifact into Maven repo. When you open any of them, there will be your familiar Maven folder structure.
Your highlighted pom.xml is multi-module project for all the sub-projects. It's used to build all sub-projects in one go.
If want to get familiar with this concept: I would suggest this tutorial: http://books.sonatype.com/mvnex-book/reference/multimodule.html
BTW, when you import sub-projects into Eclipse M2E plugin names projects according their artifact names, not according folder structure.
Upvotes: 1