Changed fields to protected scope to permit overriding functionality
This commit is contained in:
parent
9bb3fa0db8
commit
bf59e5a87c
@ -57,16 +57,18 @@ import java.util.Locale;
|
|||||||
* <p>
|
* <p>
|
||||||
* Stable is a version that is exclusively numbers. Builds are always equal, even if a different build commit hash/etc.
|
* Stable is a version that is exclusively numbers. Builds are always equal, even if a different build commit hash/etc.
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings({"unused", "SimplifiableIfStatement"})
|
@SuppressWarnings({"unused", "SimplifiableIfStatement", "WeakerAccess"})
|
||||||
public
|
public
|
||||||
class Version implements Comparable<Version> {
|
class Version implements Comparable<Version> {
|
||||||
private static final int[] PRIME = {2, 3, 5};
|
private static final int[] PRIME = {2, 3, 5};
|
||||||
|
|
||||||
private final String version;
|
// protected scope to permit overriding functionality
|
||||||
private final int[] internalVersion;
|
|
||||||
|
|
||||||
private boolean isBeta;
|
protected String version;
|
||||||
private String build;
|
protected int[] internalVersion;
|
||||||
|
|
||||||
|
protected boolean isBeta;
|
||||||
|
protected String build;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a comparable version based on only numbers
|
* Creates a comparable version based on only numbers
|
||||||
@ -102,7 +104,7 @@ class Version implements Comparable<Version> {
|
|||||||
/**
|
/**
|
||||||
* Creates a comparable version based on numbers, BETA status, and BUILD
|
* Creates a comparable version based on numbers, BETA status, and BUILD
|
||||||
*
|
*
|
||||||
* @param version must consist of only numbers with a maximum of 3 groups separated by a .
|
* @param version must consist of only numbers with a maximum of 3 groups separated by a '.' Leading '0' will be removed
|
||||||
* @param isBeta true if this is a beta build
|
* @param isBeta true if this is a beta build
|
||||||
* @param build custom build info, such as the commit sha hash
|
* @param build custom build info, such as the commit sha hash
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user