Annotation Interface EnsuresNonNull
@Documented
@Retention(RUNTIME)
@Target({METHOD,CONSTRUCTOR})
@PostconditionAnnotation(qualifier=NonNull.class)
@InheritedAnnotation
@Repeatable(List.class)
public @interface EnsuresNonNull
Indicates that the value expressions are non-null just after a method call, if the method
 terminates successfully.
 
This postcondition annotation is useful for methods that initialize a field:
 @EnsuresNonNull("theMap")
  void initialize() {
    theMap = new HashMap<>();
  }
 
  /** Throws an exception if the argument is null. */
 @EnsuresNonNull("#1")
  void assertNonNull(Object arg) { ... }
 - See Also:
- See the Checker Framework Manual:
- Nullness Checker
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic @interfaceA wrapper annotation that makes theEnsuresNonNullannotation repeatable.
- 
Required Element SummaryRequired Elements
- 
Element Details- 
valueString[] valueReturns Java expressions that areNonNullafter successful method termination.- Returns:
- Java expressions that are NonNullafter successful method termination
- See the Checker Framework Manual:
- Syntax of Java expressions
 
 
-