IDEA-381887 [java]: improve messages of Java 8 inspections

GitOrigin-RevId: 088ce28eb3b8cbbce9aa1cfc1b073fef2dab12ce
This commit is contained in:
Bas Leijdekkers
2026-01-16 13:57:13 +00:00
committed by intellij-monorepo-bot
parent 62b7fb77e7
commit bf54a73345
170 changed files with 188 additions and 188 deletions
@@ -331,15 +331,15 @@ collection.addall.can.be.replaced.with.constructor.fix.name=Replace ''{0}()'' ca
add.exception.from.field.initializer.to.constructor.throws.text=Add exception to constructor {0, choice, 0#signature|1#signature|2#signatures}
add.exception.from.field.initializer.to.constructor.throws.family.text=Add exception to constructor signatures
java.8.map.api.inspection.fix.text=Replace with ''{0}'' method call
java.8.map.api.inspection.description=Can be replaced with single ''Map.{0}'' method call
java.8.map.api.inspection.fix.family.name=Replace with single Map method call
java.8.collection.removeif.inspection.description=The loop can be replaced with 'Collection.removeIf'
java.8.collection.removeif.inspection.fix.name=Replace the loop with 'Collection.removeIf'
java.8.list.sort.inspection.description=Collections.sort could be replaced with List.sort
java.8.list.sort.inspection.fix.name=Replace with List.sort
java.8.list.replaceall.inspection.description=The loop can be replaced with 'List.replaceAll'
java.8.list.replaceall.inspection.fix.name=Replace the loop with 'List.replaceAll'
java.8.map.api.inspection.fix.text=Replace with ''{0}()'' call
java.8.map.api.inspection.description=Can be replaced with single ''Map.{0}()'' call
java.8.map.api.inspection.fix.family.name=Replace with single Map call
java.8.collection.removeif.inspection.description=Loop can be replaced with 'Collection.removeIf()'
java.8.collection.removeif.inspection.fix.name=Replace loop with 'Collection.removeIf()'
java.8.list.sort.inspection.description='Collections.sort()' can be replaced with 'List.sort()'
java.8.list.sort.inspection.fix.name=Replace with 'List.sort()'
java.8.list.replaceall.inspection.description=Loop can be replaced with 'List.replaceAll()'
java.8.list.replaceall.inspection.fix.name=Replace loop with 'List.replaceAll()'
wrap.with.optional.parameter.text=Wrap {0, choice, 1#1st|2#2nd|3#3rd|4#{0,number}th} argument using ''java.util.Optional''
wrap.with.optional.single.parameter.text=Wrap using 'java.util.Optional'
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Test {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "false"
// "Replace loop with 'Collection.removeIf()'" "false"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "false"
// "Replace loop with 'Collection.removeIf()'" "false"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "false"
// "Replace loop with 'Collection.removeIf()'" "false"
import java.util.Iterator;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Test {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "true"
// "Replace loop with 'Collection.removeIf()'" "true"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'Collection.removeIf'" "false"
// "Replace loop with 'Collection.removeIf()'" "false"
import java.util.*;
public class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
import java.util.Random;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.io.IOException;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "false"
// "Replace loop with 'List.replaceAll()'" "false"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
class Main {
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace the loop with 'List.replaceAll'" "true"
// "Replace loop with 'List.replaceAll()'" "true"
import java.util.List;
import java.util.Random;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "true"
// "Replace with 'List.sort()'" "true"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with List.sort" "false"
// "Replace with 'List.sort()'" "false"
import java.util.Collections;
import java.util.List;
@@ -1,4 +1,4 @@
// "Replace with 'compute' method call" "true"
// "Replace with 'compute()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "GENERIC_ERROR_OR_WARNING"
// "Replace with 'computeIfAbsent()' call" "GENERIC_ERROR_OR_WARNING"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "GENERIC_ERROR_OR_WARNING"
// "Replace with 'computeIfAbsent()' call" "GENERIC_ERROR_OR_WARNING"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'compute' method call" "true"
// "Replace with 'compute()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'putIfAbsent' method call" "true"
// "Replace with 'putIfAbsent()' call" "true"
import java.util.Map;
class Test {
void m1111(Map<String, Integer> map) {
@@ -1,4 +1,4 @@
// "Replace with 'putIfAbsent' method call" "true"
// "Replace with 'putIfAbsent()' call" "true"
import java.util.Map;
class Test {
void m1111(Map<String, Integer> map) {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'getOrDefault' method call" "true"
// "Replace with 'getOrDefault()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'computeIfAbsent' method call" "true"
// "Replace with 'computeIfAbsent()' call" "true"
import java.util.*;
class Test{
@@ -1,4 +1,4 @@
// "Replace with 'merge' method call" "true"
// "Replace with 'merge()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'merge' method call" "GENERIC_ERROR_OR_WARNING"
// "Replace with 'merge()' call" "GENERIC_ERROR_OR_WARNING"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'merge' method call" "true"
// "Replace with 'merge()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'merge' method call" "true"
// "Replace with 'merge()' call" "true"
import java.util.Map;
public class Main {
@@ -1,4 +1,4 @@
// "Replace with 'putIfAbsent' method call" "true"
// "Replace with 'putIfAbsent()' call" "true"
import java.util.Map;
class Test {
void m1(Map<String, Integer> map) {
@@ -1,4 +1,4 @@
// "Replace with 'putIfAbsent' method call" "true"
// "Replace with 'putIfAbsent()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;
@@ -1,4 +1,4 @@
// "Replace with 'replaceAll' method call" "true"
// "Replace with 'replaceAll()' call" "true"
import java.util.HashMap;
import java.util.Map;

Some files were not shown because too many files have changed in this diff Show More