mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-17 07:20:53 +07:00
26 lines
946 B
HTML
26 lines
946 B
HTML
<html>
|
|
<body>
|
|
Reports parts of method specification written in English that contradict with the method declaration. This includes:
|
|
<ul>
|
|
<li>Method specified to return <code>true</code> or <code>false</code> but its return type is not boolean.</li>
|
|
<li>Method specified to return <code>null</code> but it's annotated as <code>@NotNull</code> or its return type is primitive.</li>
|
|
<li>Method specified to return list but its return type is set or array.</li>
|
|
<li>And so on.</li>
|
|
</ul>
|
|
<p><b>Example:</b></p>
|
|
<pre><code>
|
|
/**
|
|
* @return true if user is found, false otherwise
|
|
*/
|
|
User findUser(String name);
|
|
</code></pre>
|
|
<p>
|
|
Note that false-positives are possible, as this inspection tries to interpret a human language. However, if the inspection reports
|
|
incorrectly, it's still possible that the description is confusing and should be rewritten.
|
|
</p>
|
|
<!-- tooltip end -->
|
|
<p>
|
|
<small>New in 2022.3</small>
|
|
</p>
|
|
</body>
|
|
</html> |