diff options
author | Gary Gregory <garydgregory@gmail.com> | 2020-01-06 11:39:33 -0500 |
---|---|---|
committer | Gary Gregory <garydgregory@gmail.com> | 2020-01-06 11:39:33 -0500 |
commit | 259ac721ce5097312d8bd93aefde26c2785f26e9 (patch) | |
tree | 9827625dfadb193a8c8480fb4c66c45b007bf74a /src/main/java/org/apache/commons/lang3/SystemUtils.java | |
parent | 365f73c4554e7753e84500a572a169f5daf1b60d (diff) | |
download | apache-commons-lang-259ac721ce5097312d8bd93aefde26c2785f26e9.tar.gz |
[LANG-1512] Add IS_JAVA_14 and IS_JAVA_15 to
org.apache.commons.lang3.SystemUtils.
Diffstat (limited to 'src/main/java/org/apache/commons/lang3/SystemUtils.java')
-rw-r--r-- | src/main/java/org/apache/commons/lang3/SystemUtils.java | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/main/java/org/apache/commons/lang3/SystemUtils.java b/src/main/java/org/apache/commons/lang3/SystemUtils.java index 6abb09e8a..e3c300c3e 100644 --- a/src/main/java/org/apache/commons/lang3/SystemUtils.java +++ b/src/main/java/org/apache/commons/lang3/SystemUtils.java @@ -1026,6 +1026,30 @@ public class SystemUtils { */ public static final boolean IS_JAVA_13 = getJavaVersionMatches("13"); + /** + * <p> + * Is {@code true} if this is Java version 14 (also 14.x versions). + * </p> + * <p> + * The field will return {@code false} if {@link #JAVA_VERSION} is {@code null}. + * </p> + * + * @since 3.10 + */ + public static final boolean IS_JAVA_14 = getJavaVersionMatches("14"); + + /** + * <p> + * Is {@code true} if this is Java version 15 (also 15.x versions). + * </p> + * <p> + * The field will return {@code false} if {@link #JAVA_VERSION} is {@code null}. + * </p> + * + * @since 3.10 + */ + public static final boolean IS_JAVA_15 = getJavaVersionMatches("15"); + // Operating system checks // ----------------------------------------------------------------------- // These MUST be declared after those above as they depend on the |