Package htsjdk.beta.plugin
Class HtsVersion
java.lang.Object
htsjdk.beta.plugin.HtsVersion
- All Implemented Interfaces:
Comparable<HtsVersion>
A class for representing 3-part versions with major, minor and patch segments. Used by
HtsCodec
, HtsEncoder
and HtsDecoder
for HTS file format and codec
versions.-
Field Summary
Modifier and TypeFieldDescriptionstatic final HtsVersion
Sentinel constant used to indicate the newest version available -
Constructor Summary
ConstructorDescriptionHtsVersion
(int major, int minor, int patch) Construct a 3 part version number.HtsVersion
(String versionString) Construct a 3 part version number from a string withe the formatmajor.minor.patch
, where each of major/minor/patch is an integer. -
Method Summary
-
Field Details
-
NEWEST_VERSION
Sentinel constant used to indicate the newest version available
-
-
Constructor Details
-
HtsVersion
public HtsVersion(int major, int minor, int patch) Construct a 3 part version number.- Parameters:
major
- major version numberminor
- minor version numberpatch
- patch number
-
HtsVersion
Construct a 3 part version number from a string withe the formatmajor.minor.patch
, where each of major/minor/patch is an integer.- Parameters:
versionString
- the version string from which to construct this version
-
-
Method Details
-
getMajorVersion
public int getMajorVersion()Get the major version integer for this version.- Returns:
- the major version integer for this version
-
getMinorVersion
public int getMinorVersion()Get the minor version integer for this version.- Returns:
- the minor version integer for this version
-
getPatchVersion
public int getPatchVersion()Get the patch version integer for this version.- Returns:
- the patch version integer for this version
-
equals
-
hashCode
public int hashCode() -
toString
-
compareTo
- Specified by:
compareTo
in interfaceComparable<HtsVersion>
-