Package htsjdk.samtools.cram.common
Class Version
- java.lang.Object
-
- htsjdk.samtools.cram.common.Version
-
- All Implemented Interfaces:
Comparable<Version>
public class Version extends Object implements Comparable<Version>
A class to represent a version information, 3 number: major, minor and build number.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(Version o)
Compare with another version.boolean
compatibleWith(Version version)
boolean
equals(Object o)
Check if another version is exactly the same as this one.int
hashCode()
String
toString()
-
-
-
Constructor Detail
-
Version
public Version(int major, int minor, int build)
-
Version
public Version(String version)
-
-
Method Detail
-
compareTo
public int compareTo(Version o)
Compare with another version.- Specified by:
compareTo
in interfaceComparable<Version>
- Parameters:
o
- another version- Returns:
- 0 if both versions are the same, a negative if the other version is higher and a positive otherwise.
-
compatibleWith
public boolean compatibleWith(Version version)
-
equals
public boolean equals(Object o)
Check if another version is exactly the same as this one.
-
-