I have taken a huge project from one of my friends and I just want to view the files just to understand some coding architectures they have implemented. On my system I don't have those jars and complete code so my Eclipse is showing almost 10,000 errors. Now I am still able to go through the code but the red errors are not allowing me to concentrate well. How can I hide all the errors in this particular project?
问题:
回答1:
I don't know if you can hide all the errors but you can
- limit the number of reported problems in
Preferences -> Java -> Compiler -> Building
, or - exlude all the files from your build path folder (
Java Build Path -> Souce -> Select source folder and Edit... -> Enter folder name and press Next -> Add '**' as Exclusion pattern
)
回答2:
Just disable JavaBuilder
in Properties -> Builders
. Sometimes after disabling JavaBuilder
error status is not updated (they are still visible). In that case do the following:
- In
Properties -> Java Build Path -> Source
remove source folder(s) - Clear project using
Build -> Clear...
- Disable
JavaBuilder
as described above - Add source folder(s) again
That way you should not be irritated with error messages any longer, but retaining all the possibilities to navigate by ctrl+click, search references etc.
回答3:
This is not the right way , just a workaround if you just want to browse the source code and not worried about compile and building it.
You just need to remove the source folder in the java build path , this will help you to get rid of those red errors that clutter your source.
Right click on Project->Properties->Java Build Path->in Source tab select your source folder and click remove.
Restart your eclipse.