Reputation: 8206
This is the first time something like that happens to me. At some point, Intellij stopped showing .java files. It stil lshows the package structure. But no .java files there. If I try to drag a file from the explorer, It opens it with this message:
// IntelliJ API Decompiler stub source generated from a class file Implementation of methods is not available
When I try to navigate to a class or file (Ctrl+N, Ctrl+Shft+N), nothing pops out. Naturally, the files are there. I tried restarting intellij, restarting the computer, reopening the project (using POM, if it matters). and running around the table a few times. Nothing helps.
Appreciate some input on how to resolve this. Can't seems to find anything like that online..
The project pane looks like this (product name is obfuscated):
Upvotes: 13
Views: 31419
Reputation: 11
Go to intellij -> File -> Settings -> Maven under "Build Tools"
For "Maven home path" select "Bundled Maven"
Upvotes: 0
Reputation: 256
For me removing the .idea folder and the closing and reopening the project fixed it, I tried everything suggested above before that apart from reinstalling intellij which i feel was a bit too much to fix 1 project.
Upvotes: 3
Reputation: 11
In my case,My idea install plugin Java Decompiler IntelliJ Plugin
. I unistall this plugin ,than it worked.
Upvotes: 0
Reputation: 1197
If its a maven project,
You need to re-open project by File--> New --> Project from existing sources--> pick your pom.xml . Then when the project is build and opened by idea.. then again go to File--> New --> Module from existing sources and again pick pom.xml.
This time pom.xml will be intelligent enough to get your source folders exactly the way you need.
My Idea version: 14.1.7 (must work for idea version > 12)
Upvotes: 4
Reputation: 1791
your java files may not be Context root folder.
Check Project Structure -> Modules -> Sources
Upvotes: 12
Reputation: 1661
Alternatively, you may want to consider reinstalling certain plugins.
All *.tpl.html files disappeared from my project window (still able to find and edit the files however). I uninstalled the AngularJS plugin and they reappeared.
Upvotes: 0
Reputation: 8206
Eventually reinstalled INTELLIJ and it worked out. I had to tell it to remove all previous settings though.
Upvotes: 1
Reputation:
Ok, looks like you have incorrectly set some of the directories as 'source'.
It also looks like this is a Maven project, a multi-module one at that.
They way you should load this into Intellj IDEA is through the Import Project -> Import from external model -> Maven -> pick the parent
pom.xml` file and IDEA will be smart enough to load and configure all the source directories for you.
Upvotes: 3