I have a lot of this warnings in project and I would like to turn it off. I'm not interested in removing those imports, so please don't tell me how to do it.
I'm using eclipse 3.4.2.
To fix this error, you must include the appropriate JAR file. External JAR files for a project are set in the Properties dialog. So are many other project attributes.
To remove those unused imports automatically, just click on the class and press the shortcut “Ctrl + Shift + O” to initilize the “Organize imports” feature.
Eclipse provide a shortcut CTRL + SHIFT + O, this shortcut command will remove all those unused imports from your code file.
If you have a file org.eclipse.jdt.core.prefs
then you can add org.eclipse.jdt.core.compiler.problem.unusedImport=ignore
.
When using vscode this file should be seen from the project root in a folder .settings
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With