mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 22:51:17 +07:00
18 lines
455 B
HTML
18 lines
455 B
HTML
<html>
|
|
<body>
|
|
Reports loops which can be collapsed into a single <code>List.replaceAll()</code> call.
|
|
<p><b>Example:</b></p>
|
|
<pre><code>
|
|
for (int i = 0; i < strings.size(); i++) {
|
|
String str = strings.get(i).toLowerCase();
|
|
strings.set(i, str);
|
|
}
|
|
</code></pre>
|
|
<p>After the quick-fix is applied:</p>
|
|
<pre><code>
|
|
strings.replaceAll(String::toLowerCase);
|
|
</code></pre>
|
|
<!-- tooltip end -->
|
|
<p><small>New in 2022.1</small></p>
|
|
</body>
|
|
</html> |