Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse showing java project src folder view as all packages and subpackages

Tags:

java

eclipse

ide

Not sure how to really ask this question since I don't know what everything is called but I'll try to do the best I can.

So as I was cleaning up my classes. I right clicked my project and selected refresh. Then all of a sudden my project view changed, the src folder shows everything as packages and '.' separated subpackages. And all my code package declarations seems now to be undiscoverable.

I've attached a photo, hopefully you can petter understand this...How can I fix this to have the correct directory view/structure.

Edit:

Here is what I have linked to my JAVA build path

I don't understand what is happening? How can all of a sudden my project screw up like it has? Any help will be much appreciated

like image 958
mosawi Avatar asked Jul 26 '15 17:07

mosawi


2 Answers

Look at the 'Java Build Path' in the project 'Properties' and check that you have the correct 'Source' folders. It looks like you may have just 'src' as a source folder when you should have 'src/main/java', 'src/test/java'...

like image 111
greg-449 Avatar answered Oct 22 '22 16:10

greg-449


I was able to fix this by maven>update project, then just refresh...

like image 40
mosawi Avatar answered Oct 22 '22 16:10

mosawi