Files
openide/java/java-impl/resources/inspectionDescriptions/NotNullFieldNotInitialized.html
Leonid Shalupov 40795fe787 IJI-2422: community/java: move resources under resources root
GitOrigin-RevId: 8b2b63fc6db476ca0c2cfe5cadd84db6c4236d0f
2025-02-05 04:43:28 +00:00

22 lines
586 B
HTML

<html>
<body>
Reports fields annotated as not-null that are not initialized in the constructor.
<p>Example:</p>
<pre><code>public class MyClass {
private @NotNull String value;
public void setValue(@NotNull String value) {
this.value = value;
}
public @NotNull String getValue() {
return value;
}
}</code></pre>
<p>
Such fields may violate the not-null constraint. In the example above, the <code>setValue</code> parameter is annotated as not-null, but
<code>getValue</code> may return null if the setter was not called.
</p>
<!-- tooltip end -->
</body>
</html>