A java.util.Comparator for version (or chapter) numbers, which have an arbitrary number of decimal points.
The code was taken from https://bugs.openjdk.java.net/browse/JDK-8134512 and http://cr.openjdk.java.net/~igerasim/8134512/04/webrev/index.html.
| Modifiers | Name | Description |
|---|---|---|
static class |
VersionsComparator.AlphaDecimalComparator |
The returned comparator compares two character sequences as though each
of them would be first transformed into a tuple of the form:
where: |
static class |
VersionsComparator.DecimalComparator |
The comparator for comparing character sequences that consist solely of decimal digits. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
static java.util.Comparator<java.lang.String> |
comparingVersions(boolean leadingZeroesFirst) |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |