java.lang.Object
jmri.util.NamedBeanUserNameComparator<B>
- Type Parameters:
B- supported type of NamedBean
- All Implemented Interfaces:
Comparator<B>
public class NamedBeanUserNameComparator<B extends NamedBean>
extends Object
implements Comparator<B>
Comparator for JMRI NamedBeans via their User Names.
If the User Names are both non-null and the AlphanumComparator tells
them apart, uses that order, otherwise uses the beans' own
NamedBean.compareTo(jmri.NamedBean) order. The AlphanumComparator treats
names such as "Siding 7" and "Siding 07" as equal, so those also fall back to
the beans' own order.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Field Details
-
comparator
-
-
Constructor Details
-
NamedBeanUserNameComparator
public NamedBeanUserNameComparator()
-
-
Method Details
-
compare
- Specified by:
comparein interfaceComparator<B extends NamedBean>
-