mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
ReadWriteStringCanBeUsedInspection: WARNING -> GENERIC_ERROR_OR_WARNING
This commit is contained in:
+1
-1
@@ -43,7 +43,7 @@ public class ReadWriteStringCanBeUsedInspection extends AbstractBaseJavaLocalIns
|
||||
ProblemHighlightType highlight;
|
||||
String message = "Can be replaced with 'Files.writeString()'";
|
||||
if (level.isAtLeast(LanguageLevel.JDK_12) || isNonUtf8Charset(bytesExpression.getArgumentList().getExpressions()[0])) {
|
||||
highlight = ProblemHighlightType.WARNING;
|
||||
highlight = ProblemHighlightType.GENERIC_ERROR_OR_WARNING;
|
||||
} else {
|
||||
highlight = ProblemHighlightType.INFORMATION;
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Replace with 'Files.writeString()'" "WARNING"
|
||||
// "Replace with 'Files.writeString()'" "GENERIC_ERROR_OR_WARNING"
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.charset.Charset;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Replace with 'Files.writeString()'" "WARNING"
|
||||
// "Replace with 'Files.writeString()'" "GENERIC_ERROR_OR_WARNING"
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.charset.Charset;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Replace with 'Files.writeString()'" "WARNING"
|
||||
// "Replace with 'Files.writeString()'" "GENERIC_ERROR_OR_WARNING"
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.charset.Charset;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Replace with 'Files.writeString()'" "WARNING"
|
||||
// "Replace with 'Files.writeString()'" "GENERIC_ERROR_OR_WARNING"
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.charset.Charset;
|
||||
|
||||
Reference in New Issue
Block a user