Package org.springframework.lang
Annotation Interface NonNullApi
@Target(PACKAGE)
@Retention(RUNTIME)
@Documented
@Nonnull
@TypeQualifierDefault({METHOD,PARAMETER})
@Deprecated
public @interface NonNullApi
Deprecated.
A common Spring annotation to declare that parameters and return values
are to be considered as non-nullable by default for a given package.
Leverages JSR-305 meta-annotations to indicate nullability in Java to common tools with JSR-305 support and used by Kotlin to infer nullability of Spring API.
Should be used at the package level in association with Nullable
annotations at the parameter and return value level.
- Since:
- 5.0
- Author:
- Sebastien Deleuze, Juergen Hoeller
- See Also:
NullMarked
instead