Package com.io7m.coffeepick.runtime
Interface RuntimeVersionType
- All Superinterfaces:
java.lang.Comparable<RuntimeVersionType>
- All Known Implementing Classes:
RuntimeVersion
@Immutable public interface RuntimeVersionType extends java.lang.Comparable<RuntimeVersionType>
A (slightly reduced) version number for Java runtimes. This version
represents a subset of the possible data present in Java runtime versions.
Specifically, this version number represents just the semantic versioning
information, plus a build number.
- See Also:
- "https://openjdk.java.net/jeps/223"
-
Method Summary
Modifier and Type Method Description java.util.Optional<java.math.BigInteger>build()default intcompareTo(RuntimeVersionType other)java.math.BigIntegermajor()java.math.BigIntegerminor()java.math.BigIntegerpatch()default java.lang.StringtoExternalMinimalString()default java.lang.StringtoExternalString()
-
Method Details
-
major
java.math.BigInteger major()- Returns:
- The major version
-
minor
java.math.BigInteger minor()- Returns:
- The minor version
-
patch
java.math.BigInteger patch()- Returns:
- The patch version
-
build
java.util.Optional<java.math.BigInteger> build()- Returns:
- The build number, if any
-
compareTo
- Specified by:
compareToin interfacejava.lang.Comparable<RuntimeVersionType>
-
toExternalString
default java.lang.String toExternalString()- Returns:
- The version as an external string (such as "3.2.1+200")
-
toExternalMinimalString
default java.lang.String toExternalMinimalString()- Returns:
- The version as an external string (such as "3.2.1+200")
-