public class DecimalNumberStringComparator extends Object implements Comparator<CharSequence>
Constructor and Description |
---|
DecimalNumberStringComparator(DecimalFormatSymbols symbols)
Constructor with decimal symbols.
|
Modifier and Type | Method and Description |
---|---|
int |
compare(CharSequence s1,
CharSequence s2) |
(package private) int |
compare(CharSequence s1,
int start1,
int end1,
CharSequence s2,
int start2,
int end2) |
static DecimalNumberStringComparator |
getInstance()
Returns the instance for the default locale.
|
static DecimalNumberStringComparator |
getInstance(Locale locale)
Returns an instance for the specified locale.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public DecimalNumberStringComparator(DecimalFormatSymbols symbols)
symbols
- the decimal symbolspublic static DecimalNumberStringComparator getInstance()
Locale.getDefault()
public static DecimalNumberStringComparator getInstance(Locale locale)
public int compare(CharSequence s1, CharSequence s2)
compare
in interface Comparator<CharSequence>
int compare(CharSequence s1, int start1, int end1, CharSequence s2, int start2, int end2)
Copyright © 2024. All rights reserved.