|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectinfo.aduna.app.AppVersion
public class AppVersion
A product version in Aduna's version format (i.e. major.minor-modifier). Where major stands for the major version number of the release, minor is the minor version number, and modifier is a modifier for the release, e.g. beta1 or RC1. Combined, this results in versions like 2.0 and 4.1-beta1.
| Constructor Summary | |
|---|---|
AppVersion()
Construct an uninitialized AppVersion. |
|
AppVersion(int major,
int minor)
Creates a new version for the supplied combination of major and minor version numbers. |
|
AppVersion(int major,
int minor,
String modifier)
Creates a new version for the supplied combination of year, quarter and release modifier. |
|
| Method Summary | |
|---|---|
boolean |
equals(Object other)
|
int |
getMajor()
Gets the version's year part. |
int |
getMinor()
Gets the version's quarter part. |
String |
getModifier()
Gets the version's release modifier part. |
int |
hashCode()
|
boolean |
newerThan(AppVersion other)
Checks if this version is newer than the specified version. |
boolean |
olderThan(AppVersion other)
Checks if this version is older than the specified version. |
static AppVersion |
parse(String versionString)
Parses a version string into a Version object. |
void |
setMajor(int major)
|
void |
setMinor(int minor)
|
void |
setModifier(String modifier)
|
String |
toString()
Returns the string represention of this version. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AppVersion()
public AppVersion(int major,
int minor)
public AppVersion(int major,
int minor,
String modifier)
| Method Detail |
|---|
public int getMajor()
public void setMajor(int major)
public int getMinor()
public void setMinor(int minor)
public String getModifier()
public void setModifier(String modifier)
public boolean equals(Object other)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic boolean olderThan(AppVersion other)
other - The version to compare to.
public boolean newerThan(AppVersion other)
other - The version to compare to.
public static AppVersion parse(String versionString)
versionString - A version string, e.g. 2003.1 or 2004.1.RC2.
NumberFormatException - If versionString could not be parsed to a version.public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||