public class Version extends Object implements Comparable<Version>
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Version otherVersion) |
boolean |
equals(Object object) |
int |
getMajor() |
int |
getMicro() |
int |
getMinor() |
boolean |
greaterOrEqualsThan(Version other)
Returns true if
this is greater or equals that other . |
boolean |
greaterThan(Version other)
Returns true if
this is greater that other . |
int |
hashCode() |
boolean |
inside(VersionRange range) |
boolean |
lesserOrEqualsThan(Version other)
Returns true if
this is lesser or equals that other . |
boolean |
lesserThan(Version other)
Returns true if
this is lesser that other . |
String |
toString() |
String |
toString(String prefix,
String separator) |
public static final Version INFINITE
public Version(String version)
public int getMajor()
public int getMinor()
public int getMicro()
public boolean greaterThan(Version other)
this
is greater that other
.other
- public boolean greaterOrEqualsThan(Version other)
this
is greater or equals that other
.other
- public boolean lesserThan(Version other)
this
is lesser that other
.other
- public boolean lesserOrEqualsThan(Version other)
this
is lesser or equals that other
.other
- public boolean inside(VersionRange range)
public int compareTo(Version otherVersion)
compareTo
in interface Comparable<Version>
Copyright © 2001-2019 Codehaus. All Rights Reserved.