@Documented
@Retention(value=CLASS)
@Target(value={FIELD,METHOD,PARAMETER,LOCAL_VARIABLE})
public @interface Nullable
null
. The specific semantics
implied by this annotation depend on the kind of element the annotation is
applied to.
null
.null
for this parameter. The documentation for the method should
describe the behavior of the method in the event this parameter is
null
.
null
. The documentation
for the method should describe the meaning of a null
reference being
returned. Overriding methods may optionally use the NotNull
annotation instead of this annotation for the method, indicating that the
overriding method (and any method which overrides it) will never return a
null
reference.
The NullUsageProcessor
annotation processor validates certain usage
scenarios for this annotation, with compile-time errors or warnings reported
for misuse. For detailed information about the supported analysis, see the
documentation for NullUsageProcessor
.