< prev index next >

src/java.compiler/share/classes/javax/lang/model/SourceVersion.java

Print this page

        

@@ -213,22 +213,30 @@
      *
      * Additions in this release include text blocks.
      *
      * @since 15
      */
-     RELEASE_15;
+    RELEASE_15,
+
+    /**
+     * The version recognized by the Java Platform, Standard Edition
+     * 16.
+     *
+     * @since 16
+     */
+     RELEASE_16;
 
     // Note that when adding constants for newer releases, the
     // behavior of latest() and latestSupported() must be updated too.
 
     /**
      * Returns the latest source version that can be modeled.
      *
      * @return the latest source version that can be modeled
      */
     public static SourceVersion latest() {
-        return RELEASE_15;
+        return RELEASE_16;
     }
 
     private static final SourceVersion latestSupported = getLatestSupported();
 
     /*

@@ -239,11 +247,11 @@
      * need to be updated accordingly.
      */
     private static SourceVersion getLatestSupported() {
         int intVersion = Runtime.version().feature();
         return (intVersion >= 11) ?
-            valueOf("RELEASE_" + Math.min(15, intVersion)):
+            valueOf("RELEASE_" + Math.min(16, intVersion)):
             RELEASE_10;
     }
 
     /**
      * Returns the latest source version fully supported by the
< prev index next >