Only show warnings from some folders in eclipse

I am working on a larger Java codebase in eclipse, which currently emits about 7000 warnings. However, I work in fairly isolated parts, in a few specific source folders and namespaces. I would like eclipse to display warnings only for my modules on the Problems tab, and not for the entire code base. It currently shows the first 100 alerts that are not related to my modules. Is it possible?

Update Thanks for all the nice answers. I changed the question a bit so that it is clear that I'm talking about several, albeit rather small, folders and namespaces.

+8
java eclipse compiler-warnings suppress-warnings
source share
5 answers

The Problems view has a triangle pointing down in the upper right corner next to other icons. Select this triangle and select Configure Contents... from the menu. See below:

Configure Contents in Problem View

You can apply various configurations to control what the items show. I have the following configurations:

Configure Contents Dialog

Configure Contents Dialog

Note that both of these configurations have a selected area of ​​"On selected element and its children". This will only show problems associated with the file in the editor or package selected in the package view, for example.

+17
source share

You can create a new “Work Set” and limit alerts in the “Work Set” area. To change the area of ​​your “Problems” tab, select “View-Menu” (small triangle) and select “Customize Content”, there you will find various options for customizing the area.

+3
source share

I believe that if you activate Mylyn in your project (in a task-oriented interface) , you can set the filtering of problems in the context of the task, displaying only warnings that are relevant to your current "context".

Or you can customize the contents of the contents of the problem to display only warnings / errors for the selected item.

configure content

selected element

+2
source share

You can limit the warning to the selected resource (s), see the configuration of problematic problems (by clicking the small triangle in the upper right corner of the view).

Problem view configuration

+1
source share

Currently, the best way is to declare a working set and set up a problem view to display content from that working set only.

The best solution (possibly) coming directly from JDT. See bug for more details.

+1
source share

All Articles