How can I disable annoying warning/hint in NetBeans 8.1

那年仲夏 提交于 2019-12-11 01:27:36

问题


I am working with Java and Jersey in NetBeans and all my endpoints are flagged with the following hint: "Convert Method To Asynchronous"

This hint really pollutes the right-hand gutter where I usually look for code changes/errors.

There is nothing in preferences -> editor -> hints that seems to affect this hint.

Cheers


回答1:


You can use the @SupressWarning annotation, or, by hovering the mouse-pointer over the warning, there are options to disable for instance (auto-generates @SupressWarning), for file, for package, for project or "forever" (pah-dum-pshh =P).

However, most warnings are there for a reason, and although some can show up by "mistake" while your class isn't fully implemented yet, if your class is complete and a warning is still present, you're advised to correct it rather than suppress it.




回答2:


I checked through the NetBeans source code (here) and there's no way to disable/suppress that warning short of removing the REST module (/enterprise/modules/org-netbeans-modules-webscv-rest.jar).



来源:https://stackoverflow.com/questions/39758868/how-can-i-disable-annoying-warning-hint-in-netbeans-8-1

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!