|
Lizzy v1.1.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectchristophedelory.xml.Version
public class Version
A generic version information, composed of a version number, a revision number and a step number.
| Field Summary | |
|---|---|
static Version |
CURRENT
The current version of this project. |
| Constructor Summary | |
|---|---|
Version(int version,
int revision,
int step)
Builds a new Version instance which should keep a specific version, revision and step numbers. |
|
| Method Summary | |
|---|---|
Object |
clone()
Creates and returns a "shallow" copy of this object. |
int |
compareTo(Object o)
|
boolean |
equals(Object obj)
Indicates whether some other object is "equal to" this one. |
int |
getRevision()
Returns the revision number kept by this instance. |
int |
getStep()
Returns the step number kept by this instance. |
int |
getVersion()
Returns the version number kept by this instance. |
int |
hashCode()
|
String |
toString()
Returns a string representation of this version information. |
static Version |
valueOf(String name)
Builds a version information from the specified string. |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static Version CURRENT
| Constructor Detail |
|---|
public Version(int version,
int revision,
int step)
Version instance which should keep a specific version, revision and step numbers.
version - the version number.revision - the revision number.step - the step number.
IndexOutOfBoundsException - if one of the numbers is strictly negative.| Method Detail |
|---|
public static Version valueOf(String name)
name - the version string.
NullPointerException - if the version string is null.
IllegalArgumentException - if the version string is malformed.
IndexOutOfBoundsException - if one of the numbers is strictly negative.
NumberFormatException - if the version string contains a non-parsable integer.toString()public int getVersion()
public int getRevision()
public int getStep()
public int compareTo(Object o)
public boolean equals(Object obj)
equals in class Objectobj - the reference object with which to compare. A Version instance is expected.
true if this object is the same as the obj argument; false otherwise.public int hashCode()
hashCode in class Object
public Object clone()
throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedException - shall not be thrown, because this class is cloneable.Object.clone()public String toString()
<version>.<revision>.<step>".
toString in class Object
|
© 2008-2009 Christophe Delory | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||