Java file removed from classpath(?!)

Answered

Hello there,

By some "unknown" reason, one file of my project is not being recognized anymore as a source file, and as you can see in the attached picture, the file's icon also changed. I tried to associate it back with a "java editor" but no success. When I try to open it, an empty "editor" is open, but without the code.

The code still there (I can see in other editors), but intellij is not recognizing it and removed it from the classpath. 

How can I fix this? and What happened here?

Thanks!

2 comments
Comment actions Permalink

The file is mapped to the wrong file type, see https://stackoverflow.com/a/13374653/104891 for the solution.

1
Comment actions Permalink

Thanks Serge Baranov

A right click on the file / Override File Type and choose back 'Java',  fixed the issue.

0

Please sign in to leave a comment.