., -, +, and _. The transition between letter and digit (or vice-versa) is
also considered to be an invisible separator.
Versions may be compared, sorted, used as hash keys, and iterated.
| Modifier and Type | Class and Description |
|---|---|
| public class | Version.Iterator
An iterator over the parts of a version. |
| pack-priv static class |
| Modifier and Type | Field and Description |
|---|---|
| private static final int | |
| private static final int | |
| private static final int | |
| private static final int | |
| private static final int | |
| private final String |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv int | |
| pack-priv static int | |
| public int | Returns: A negative integer, zero, or a positive integer as this module version is less than, equal to, or greater than the given module versionThe module version to compare that)Implements java. |
| pack-priv static int | Returns: the end character index in the version stringthe cookie cookie)Get the token end index from the cookie. |
| pack-priv static int | Returns: the start character index in the version stringthe cookie cookie)Get the token start index from the cookie. |
| pack-priv static int | |
| public boolean | Returns: true if, and only if, the given object is a module
reference that is equal to this module referencethe object to which this object is to be compared ob)Overrides java. |
| public int | Returns: The hash-code value for this module versionOverrides java. |
| pack-priv boolean | |
| pack-priv static boolean | |
| pack-priv static boolean | |
| pack-priv static boolean | |
| public Version. | |
| pack-priv long | Returns: the next cookie value in the token sequencethe cookie ( cookie)0L indicates start of search)Go to the next token. |
| public static Version | |
| pack-priv static int | |
| public String | Returns: The normalized string.Overrides java. |
| pack-priv Object |
| TOK_INITIAL | back to summary |
|---|---|
| private static final int TOK_INITIAL | |
| TOK_PART_ALPHA | back to summary |
|---|---|
| private static final int TOK_PART_ALPHA | |
| TOK_PART_NUMBER | back to summary |
|---|---|
| private static final int TOK_PART_NUMBER | |
| TOK_SEP | back to summary |
|---|---|
| private static final int TOK_SEP | |
| TOK_SEP_EMPTY | back to summary |
|---|---|
| private static final int TOK_SEP_EMPTY | |
| version | back to summary |
|---|---|
| private final String version | |
| Version | back to summary |
|---|---|
| private Version(String v) | |
| comparePart | back to summary |
|---|---|
| pack-priv int comparePart(long cookie, Version other, long otherCookie) | |
| compareSep | back to summary |
|---|---|
| pack-priv static int compareSep(int sep1, int sep2) | |
| compareTo | back to summary |
|---|---|
| public int compareTo(Version that) Implements java. Compares this module version to another module version. Module versions are compared as described in the class description. | |
| cookieToEndIndex | back to summary |
|---|---|
| pack-priv static int cookieToEndIndex(long cookie) Get the token end index from the cookie. The end index is stored in the second 28 bits (bits 28-55) of the cookie.
| |
| cookieToStartIndex | back to summary |
|---|---|
| pack-priv static int cookieToStartIndex(long cookie) Get the token start index from the cookie. The start index is stored in the lowest 28 bits (bits 0-27) of the cookie.
| |
| cookieToToken | back to summary |
|---|---|
| pack-priv static int cookieToToken(long cookie) Get the token type from the cookie. The token type is stored in bits 56 and up in the cookie. The value will be one of:
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object ob) Overrides java. Tests this module version for equality with the given object. If the given object is not a This method satisfies the general contract of the | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Computes a hash code for this module version. The hash code is based upon the components of the version and
satisfies the general contract of the
| |
| hasNext | back to summary |
|---|---|
| pack-priv boolean hasNext(long cookie) | |
| isValidAlphaPart | back to summary |
|---|---|
| pack-priv static boolean isValidAlphaPart(int codePoint) | |
| isValidNumberPart | back to summary |
|---|---|
| pack-priv static boolean isValidNumberPart(int codePoint) | |
| isValidSeparator | back to summary |
|---|---|
| pack-priv static boolean isValidSeparator(int codePoint) | |
| iterator | back to summary |
|---|---|
| public Version. Construct a new iterator over the parts of this version string. | |
| next | back to summary |
|---|---|
| pack-priv long next(long cookie) throws IllegalArgumentException Go to the next token.
| |
| parse | back to summary |
|---|---|
| public static Version parse(String v) Parses the given string as a version string.
| |
| sepMagnitude | back to summary |
|---|---|
| pack-priv static int sepMagnitude(int codePoint) | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns the normalized string representation of this version. | |
| writeReplace | back to summary |
|---|---|
| pack-priv Object writeReplace() | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public String | |
| public BigInteger | Returns: the current numeric part as aBigIntegerGet the current numeric part, as a |
| public int | Returns: the current numeric part as anintGet the current numeric part, as an |
| public long | Returns: the current numeric part as alongGet the current numeric part, as a |
| public String | Returns: the current numeric part as aStringGet the current numeric part, as a |
| public int | Returns: the code point of the current separatorGet the code point of the current separator. |
| public boolean | Returns: true if more tokens remain, false otherwiseDetermine whether another token exists in this version. |
| public boolean | Returns: true if the token is an alphabetical part, false otherwiseDetermine if the current token is an alphabetical part. |
| public boolean | Returns: true if the token is an empty separator, false otherwiseDetermine if the current token is an empty (or zero-length alphabetical-to-numeric or numeric-to-alphabetical) separator. |
| public boolean | Returns: true if the token is a non-empty separator, false otherwiseDetermine if the current token is a non-empty separator. |
| public boolean | Returns: true if the token is a numeric part, false otherwiseDetermine if the current token is a numeric part. |
| public boolean | Returns: true if the token is a separator, false otherwiseDetermine if the current token is some kind of part (alphabetical or numeric). |
| public boolean | Returns: true if the token is a separator, false otherwiseDetermine if the current token is some kind of separator (a character or a zero-length alphabetical-to-numeric or numeric-to-alphabetical transition). |
| public int | |
| public void |
| cookie | back to summary |
|---|---|
| pack-priv long cookie | |
| Iterator | back to summary |
|---|---|
| pack-priv Iterator() | |
| getAlphaPart | back to summary |
|---|---|
| public String getAlphaPart() Get the current alphabetical part. If the iterator is not positioned on an alphabetical part (i.e.
| |
| getNumberPartAsBigInteger | back to summary |
|---|---|
| public BigInteger getNumberPartAsBigInteger() Get the current numeric part, as a
| |
| getNumberPartAsInt | back to summary |
|---|---|
| public int getNumberPartAsInt() Get the current numeric part, as an
| |
| getNumberPartAsLong | back to summary |
|---|---|
| public long getNumberPartAsLong() Get the current numeric part, as a
| |
| getNumberPartAsString | back to summary |
|---|---|
| public String getNumberPartAsString() Get the current numeric part, as a
| |
| getSeparatorCodePoint | back to summary |
|---|---|
| public int getSeparatorCodePoint() Get the code point of the current separator. If the iterator is not positioned on a non-empty separator
(i.e.
| |
| hasNext | back to summary |
|---|---|
| public boolean hasNext() Determine whether another token exists in this version.
| |
| isAlphaPart | back to summary |
|---|---|
| public boolean isAlphaPart() Determine if the current token is an alphabetical part.
| |
| isEmptySeparator | back to summary |
|---|---|
| public boolean isEmptySeparator() Determine if the current token is an empty (or zero-length alphabetical-to-numeric or numeric-to-alphabetical) separator.
| |
| isNonEmptySeparator | back to summary |
|---|---|
| public boolean isNonEmptySeparator() Determine if the current token is a non-empty separator.
| |
| isNumberPart | back to summary |
|---|---|
| public boolean isNumberPart() Determine if the current token is a numeric part.
| |
| isPart | back to summary |
|---|---|
| public boolean isPart() Determine if the current token is some kind of part (alphabetical or numeric).
| |
| isSeparator | back to summary |
|---|---|
| public boolean isSeparator() Determine if the current token is some kind of separator (a character or a zero-length alphabetical-to-numeric or numeric-to-alphabetical transition).
| |
| length | back to summary |
|---|---|
| public int length() Get the length of the current token. If there is no current token, zero is returned.
| |
| next | back to summary |
|---|---|
| public void next() Move to the next token.
| |
| Modifier and Type | Field and Description |
|---|---|
| private static final long | |
| private final String |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv Object |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID | |
| string | back to summary |
|---|---|
| private final String string | |
| Serialized | back to summary |
|---|---|
| pack-priv Serialized(final String string) | |
| readResolve | back to summary |
|---|---|
| pack-priv Object readResolve() | |