public class IlrVersion extends java.lang.Object implements java.lang.Comparable<IlrVersion>, java.io.Serializable
IlrVersion class represents the version number for a RuleApp or a
ruleset.| Constructor and Description |
|---|
IlrVersion(int major,
int minor)
Constructs an
IlrVersion instance from a major and a minor
number. |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(IlrVersion o)
Compares the version number of this
IlrVersion instance
to another object. |
boolean |
equals(java.lang.Object obj)
Overrides
java.lang.Object#equals(java.lang.Object). |
int |
getMajor()
Retrieves the major number of this version instance.
|
int |
getMinor()
Retrieves the minor number of this version instance.
|
int |
hashCode()
Overrides
java.lang.Object#hashCode(). |
static IlrVersion |
parseVersion(java.lang.String version)
Retrieves an
IlrVersion object that represents the version
specified by a string. |
java.lang.String |
toString()
Overrides
java.lang.Object#toString(). |
public IlrVersion(int major,
int minor)
IlrVersion instance from a major and a minor
number.major - The major version number. This value must be greater than
0.minor - The minor version number. This value must be greater than
or equal to 0.public static IlrVersion parseVersion(java.lang.String version) throws IlrFormatException
IlrVersion object that represents the version
specified by a string.IlrFormatException - if the string cannot be parsed as a version.version - The String to be parsed.IlrVersion object that represents the version
specified by a string.public int getMajor()
public int getMinor()
public int compareTo(IlrVersion o)
IlrVersion instance
to another object.compareTo in interface java.lang.Comparable<IlrVersion>o - The object with which to compare version numbers.Comparable.compareTo(java.lang.Object)public boolean equals(java.lang.Object obj)
java.lang.Object#equals(java.lang.Object).equals in class java.lang.Objectobj - The object to test against this version instance.true if obj is the same
as this version instance.Object.equals(java.lang.Object)public int hashCode()
java.lang.Object#hashCode().hashCode in class java.lang.ObjectObject.hashCode()public java.lang.String toString()
java.lang.Object#toString().toString in class java.lang.ObjectString representation of this object.Object.toString()© Copyright IBM Corp. 1987, 2017