< prev index next >

src/java.base/share/classes/jdk/internal/javac/PreviewFeature.java

Print this page

 50  // CLASS retention will hopefully be sufficient for the purposes at hand
 51 @Retention(RetentionPolicy.CLASS)
 52 // *Not* @Documented
 53 public @interface PreviewFeature {
 54     /**
 55      * Name of the preview feature the annotated API is associated
 56      * with.
 57      */
 58     public Feature feature();
 59 
 60     public boolean reflective() default false;
 61 
 62     /**
 63      * Enum of preview features in the current release.
 64      * Values should be annotated with the feature's {@code JEP}.
 65      */
 66     public enum Feature {
 67         // not used, but required for interim javac to not warn.
 68         VIRTUAL_THREADS,
 69         FOREIGN,



 70         @JEP(number=459, title="String Templates", status="Second Preview")
 71         STRING_TEMPLATES,
 72         @JEP(number=477, title="Implicitly Declared Classes and Instance Main Methods", status="Third Preview")
 73         IMPLICIT_CLASSES,
 74         @JEP(number=481, title="Scoped Values", status="Third Preview")
 75         SCOPED_VALUES,
 76         @JEP(number=480, title="Structured Concurrency", status="Third Preview")
 77         STRUCTURED_CONCURRENCY,
 78         @JEP(number=466, title="ClassFile API", status="Second Preview")
 79         CLASSFILE_API,
 80         @JEP(number=473, title="Stream Gatherers", status="Second Preview")
 81         STREAM_GATHERERS,
 82         @JEP(number=476, title="Module Import Declarations", status="Preview")
 83         MODULE_IMPORTS,
 84         LANGUAGE_MODEL,
 85         /**
 86          * A key for testing.
 87          */
 88         @JEP(number=2_147_483_647, title="Test Feature")
 89         TEST,

 50  // CLASS retention will hopefully be sufficient for the purposes at hand
 51 @Retention(RetentionPolicy.CLASS)
 52 // *Not* @Documented
 53 public @interface PreviewFeature {
 54     /**
 55      * Name of the preview feature the annotated API is associated
 56      * with.
 57      */
 58     public Feature feature();
 59 
 60     public boolean reflective() default false;
 61 
 62     /**
 63      * Enum of preview features in the current release.
 64      * Values should be annotated with the feature's {@code JEP}.
 65      */
 66     public enum Feature {
 67         // not used, but required for interim javac to not warn.
 68         VIRTUAL_THREADS,
 69         FOREIGN,
 70         @JEP(number=401, title="Value Classes and Objects", status = "Preview")
 71         VALUE_OBJECTS,
 72 
 73         @JEP(number=459, title="String Templates", status="Second Preview")
 74         STRING_TEMPLATES,
 75         @JEP(number=477, title="Implicitly Declared Classes and Instance Main Methods", status="Third Preview")
 76         IMPLICIT_CLASSES,
 77         @JEP(number=481, title="Scoped Values", status="Third Preview")
 78         SCOPED_VALUES,
 79         @JEP(number=480, title="Structured Concurrency", status="Third Preview")
 80         STRUCTURED_CONCURRENCY,
 81         @JEP(number=466, title="ClassFile API", status="Second Preview")
 82         CLASSFILE_API,
 83         @JEP(number=473, title="Stream Gatherers", status="Second Preview")
 84         STREAM_GATHERERS,
 85         @JEP(number=476, title="Module Import Declarations", status="Preview")
 86         MODULE_IMPORTS,
 87         LANGUAGE_MODEL,
 88         /**
 89          * A key for testing.
 90          */
 91         @JEP(number=2_147_483_647, title="Test Feature")
 92         TEST,
< prev index next >