public enum NamedObjectSort extends Enum<NamedObjectSort> implements Comparator<NamedObject>
Enum Constant and Description |
---|
alphabetical
Alphabetical sort.
|
natural
Natural sort.
|
Modifier and Type | Method and Description |
---|---|
abstract int |
compare(NamedObject namedObject1,
NamedObject namedObject2) |
static NamedObjectSort |
getNamedObjectSort(boolean alphabeticalSort) |
static NamedObjectSort |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static NamedObjectSort[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public static final NamedObjectSort alphabetical
public static final NamedObjectSort natural
public static NamedObjectSort[] values()
for (NamedObjectSort c : NamedObjectSort.values()) System.out.println(c);
public static NamedObjectSort valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static NamedObjectSort getNamedObjectSort(boolean alphabeticalSort)
public abstract int compare(NamedObject namedObject1, NamedObject namedObject2)
compare
in interface Comparator<NamedObject>
Comparator.compare(java.lang.Object,
java.lang.Object)
Copyright © 2000-2015 Sualeh Fatehi. All rights reserved.