@Retention(value=SOURCE) @Target(value=METHOD) public @interface Java9
@Java9 marks a method that is only used when running on Java 9 or
later. It is primarily for tooling authors and library maintainers. IDEs may
safely delete imports that appear unused when this annotation is present.
Retention and effect: Present only in the source and discarded by the compiler. It has no runtime effect unless recognised by build tooling.
@Java9
void newApiCall();
Use Jvm.isJava9Plus() to guard such calls at runtime.
TargetMajorVersionCopyright © 2026 Chronicle Software Ltd. All rights reserved.