Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.axis2.description
Class Version

    java.lang.Object
      org.apache.axis2.description.Version

All Implemented Interfaces:
  java.io.Serializable, java.lang.Comparable<Version>

    public class Version

extends java.lang.Object
implements java.io.Serializable, java.lang.Comparable<Version>

Class representing a version number and implementing a comparison algorithm compatible with Maven. This class is primarily used for module versions.

See Also:
  Serialized Form

Field Summary
`static Version` | `SNAPSHOT`

Constructor Summary
`Version(int[] components, java.lang.String qualifier)` Constructor.
`Version(java.lang.String versionString)` Constructor that parses the version from a string.

Method Summary
`int` | `compareTo(Version o)`
`boolean` | `equals(java.lang.Object obj)`
`int` | `hashCode()`
`java.lang.String` | `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### SNAPSHOT

    public static final Version SNAPSHOT

Constructor Detail

### Version

    public Version(int[] components,
                   java.lang.String qualifier)

  Constructor.

  Parameters:
    `components` - the numeric components of the version; may be null for SNAPSHOT version
    `qualifier` - the qualifier

### Version

    public Version(java.lang.String versionString)
            throws java.text.ParseException

  Constructor that parses the version from a string. The version must have the following format:

       integer ( "." integer )* ( "-" qualifier )?

  Parameters:
    `versionString` - the string representation of the version
  Throws:
    `java.text.ParseException` - if the version is not in the correct format

Method Detail

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### equals

    public boolean equals(java.lang.Object obj)

  Overrides:
    `equals` in class `java.lang.Object`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

### compareTo

    public int compareTo(Version o)

  Specified by:
    `compareTo` in interface `java.lang.Comparable<Version>`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2011 The Apache Software Foundation. All Rights Reserved.