Some constants declared in this class are final, but they are not final in the API release JAR. Meaning, that users can use them in if conditions and compare them against constant values without worrying about dead code elimination. Make sure to use the API release JAR in your classpath when compiling classes against the repository runtime.
public static final int | VERSION_FULL_COMPOUND = 8009 A compound version representation of the saker.nest repository release. |
public static final int | VERSION_MAJOR = 0 The major version of the saker.nest repository release. |
public static final int | VERSION_MINOR = 8 The minor version of the saker.nest repository release. |
public static final int | VERSION_PATCH = 9 The patch version of the saker.nest repository release. |
public static final String | VERSION_STRING_FULL = "0.8.9" |
The field has the value of
VERSION_MAJOR * 1_000_000 + VERSION_MINOR * 1_000 + VERSION_PATCH
.
It can be easily used in conditional statements to query the runtime for available features.
if (Versions.VERSION_FULL_COMPOUND >= 8_001) { // use features from 0.8.1 } else if (Versions.VERSION_FULL_COMPOUND >= 1_000_000) { // use features from 1.0.0 }Note that you shouldn't start your version numbers with the number
0
, as that represents an octal
number.The major version will change when there are backward incompatible changes between releases.
The minor version changes when changes are made to the repository implementation, but they are backward compatible.
The minor version is also changed when features are deprecated but not yet removed from the implementation.
The patch version changes when bugfixes are added to the implementation.