public class VersionNumber extends Object implements Comparable<VersionNumber>
Modifier and Type | Method and Description |
---|---|
int |
compareTo(VersionNumber other) |
boolean |
equals(Object other) |
String |
getBuildLabel()
The build label if there is one.
|
int |
getDSEPatch()
The DSE patch version number (will only be present for version of Cassandra in DSE).
|
int |
getMajor()
The major version number.
|
int |
getMinor()
The minor version number.
|
int |
getPatch()
The patch version number.
|
List<String> |
getPreReleaseLabels()
The pre-release labels if relevant, i.e.
|
int |
hashCode() |
VersionNumber |
nextStable()
The next stable version, i.e.
|
static VersionNumber |
parse(String version)
Parse a version from a string.
|
String |
toString() |
public static VersionNumber parse(String version)
version
- the string to parseIllegalArgumentException
- if the provided string does not
represent a valid version.public int getMajor()
public int getMinor()
public int getPatch()
public int getDSEPatch()
public List<String> getPreReleaseLabels()
null
if the version number
doesn't have one.public String getBuildLabel()
null
if the version number
doesn't have one.public VersionNumber nextStable()
public int compareTo(VersionNumber other)
compareTo
in interface Comparable<VersionNumber>
Copyright © 2012–2017. All rights reserved.