fix <!-- tooltip end --> problems in Java 8 inspection descriptions

This commit is contained in:
Bas Leijdekkers
2017-02-25 14:47:26 +01:00
parent 6a379d0668
commit dddf317695
13 changed files with 31 additions and 31 deletions
@@ -1,12 +1,12 @@
<html>
<body>
Reports anonymous classes which could be transformed to constructor or factory method call accepting lambda expression.
<!-- tooltip end -->
<p>The following classes are reported by this inspection:</p>
<ul>
<li><b>ThreadLocal</b> anonymous classes having <b>initialValue()</b> method (could be replaced with <b>ThreadLocal.withInitial</b>)</li>
<li><b>Thread</b> anonymous classes having <b>run()</b> method (could be replaced with <b>new Thread(Runnable)</b></li>
</ul>
<small>New in 2016.3</small>
<!-- tooltip end -->
<p><small>New in 2016.3</small>
</body>
</html>
@@ -2,9 +2,9 @@
<body>
Inspection looks for Comparators defined as lambda expressions which could be expressed using
methods like <code>Comparator.comparing()</code>.
<!-- tooltip end -->
<p>Some comparators like <code>(person1, person2) -> person1.getName().compareTo(person2.getName())</code>
could be simplified like this: <code>Comparator.comparing(Person::getName)</code>.</p>
<small>New in 2016.3</small>
<!-- tooltip end -->
<p><small>New in 2016.3</small>
</body>
</html>
@@ -2,10 +2,10 @@
<body>
This inspection warns if trivial lambda expression is used where there's an alternative method which behaves the same way but
accepts concrete value instead of lambda.
<!-- tooltip end -->
<p>
For example, <code>Optional.orElseGet(() -> null)</code> can be replaced with <code>Optional.orElse(null)</code>.
</p>
<small>New in 2017.1</small>
<!-- tooltip end -->
<p><small>New in 2017.1</small></p>
</body>
</html>
@@ -1,11 +1,11 @@
<html>
<body>
This inspection reports method references mapped to Comparator interface which don't fulfill its contract.
<!-- tooltip end -->
<p>
Some method references like <code>Integer::max</code> can be mapped to <code>Comparator</code> interface.
However using them as <code>Comparator</code> is useless and result might be unpredictable.
</p>
<small>New in 2016.3</small>
<!-- tooltip end -->
<p><small>New in 2016.3</small></p>
</body>
</html>
@@ -1,14 +1,14 @@
<html>
<body>
This inspection looks for loops which could be replaced with <code>Arrays.setAll()</code> call.
<!-- tooltip end -->
<p>The loops like this are reported:</p>
<pre>
for (int i=0; i&lt;array.length; i++) {
array[i] = calc(i);
}
</pre>
<p>This inspection is available since Java 8 only.</p>
<small>New in 2017.1</small>
<!-- tooltip end -->
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<p><small>New in 2017.1</small>
</body>
</html>
@@ -1,7 +1,6 @@
<html>
<body>
The inspection reports the loops which could be collapsed into single <code>Collection.removeIf</code> call.
<!-- tooltip end -->
<p>The loops like this are reported:</p>
<pre>
for (Iterator&lt;String&gt; it = collection.iterator(); it.hasNext(); ) {
@@ -11,7 +10,8 @@ The inspection reports the loops which could be collapsed into single <code>Coll
}
}
</pre>
<p>This inspection is available since Java 8 only.</p>
<!-- tooltip end -->
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<small>New in 2016.3</small>
</body>
</html>
@@ -2,7 +2,7 @@
<body>
Inspection detects calls to <code>Collections.sort(list, comparator)</code> which could be replaced with <code>list.sort(comparator)</code>.
<!-- tooltip end -->
<p>This inspection is available since Java 8 only.</p>
<small>New in 2016.3</small>
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<p><small>New in 2016.3</small>
</body>
</html>
@@ -2,7 +2,6 @@
<body>
Inspection detects calls to <code>Map.get</code> which could be replaced with <code>getOrDefault</code>, <code>computeIfAbsent</code> or
<code>putIfAbsent</code>.
<!-- tooltip end -->
<ul>
<li><b>Map.getOrDefault</b> method could be used to replace the code like this:
<pre>
@@ -41,7 +40,8 @@ Inspection detects calls to <code>Map.get</code> which could be replaced with <c
</li>
</ul>
<p>This inspection is available since Java 8 only.</p>
<small>New in 2016.3</small>
<!-- tooltip end -->
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<p><small>New in 2016.3</small>
</body>
</html>
@@ -2,12 +2,12 @@
<body>
This inspection suggests to replace <code>for(Entry&lt;?,?&gt; entry : map.entrySet()) {...}</code> or
<code>map.entrySet().forEach(entry -&gt; ...)</code> with <code>map.forEach((key, value) -> ...)</code>.
<!-- tooltip end -->
<p>
When checkbox is checked, only <code>entrySet().forEach()</code> cases will be reported.
However the quick-fix action will be available for <code>for</code>-loops as well.
</p>
<p>This inspection is available since Java 8 only.</p>
<small>New in 2017.1</small>
<!-- tooltip end -->
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<p><small>New in 2017.1</small>
</body>
</html>
@@ -1,9 +1,9 @@
<html>
<body>
Reports lambda expressions which could be replaced with JDK method call.
<!-- tooltip end -->
<p>For example, the expression <code>x -&gt; x</code> of type <code>Function&lt;T, T&gt;</code>
could be replaced with <code>Function.identity()</code> call.</p>
<small>New in 2017.1</small>
could be replaced with <code>Function.identity()</code> call.</p>
<!-- tooltip end -->
<p><small>New in 2017.1</small>
</body>
</html>
@@ -2,12 +2,12 @@
<body>
This inspection warns about useless Stream or Optional calls like <code>map(x -> x)</code> or <code>filter(x -> true)</code>,
useless <code>sorted</code> or <code>distinct</code>.
<!-- tooltip end -->
<p>Note that a mapping operation in code like <code>streamOfIntegers.map(Integer::valueOf)</code> works as <code>requireNonNull</code>
check:
if stream contains a <code>null</code>, it will throw <code>NullPointerException</code>, thus it's not absolutely useless. Uncheck the
"Report useless boxing in Stream.map" checkbox if you don't want such cases to be reported.</p>
<p>This inspection is available since Java 8 only.</p>
<small>New in 2017.1</small>
<!-- tooltip end -->
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher.</p>
<p><small>New in 2017.1</small>
</body>
</html>
@@ -3,7 +3,7 @@
This inspection detects collectors which could be simplified. In particular some cascaded <code>groupingBy</code> collectors
could be expressed with simpler <code>toMap</code> collector which also will likely be more performant.
<!-- tooltip end -->
<p>This inspection is available since Java 8 only.</p>
<small>New in 2017.1</small>
<p>This inspection only reports if the project or module is configured to use a language level of 8 or higher. </p>
<p><small>New in 2017.1</small>
</body>
</html>
@@ -1,12 +1,12 @@
<html>
<body>
This inspection converts Stream API chain into classical loop.
<!-- tooltip end -->
<p>
Note that sometimes this inspection might cause slight semantic changes.
Especially care should be taken when it comes to short-circuiting, as it's not specified how many elements will be actually read when
the stream short-circuits.
</p>
<small>New in 2017.1</small>
<!-- tooltip end -->
<p><small>New in 2017.1</small>
</body>
</html>