Class DFUtilities.NamedObjComparator

  • All Implemented Interfaces:
    java.util.Comparator
    Enclosing class:
    DFUtilities

    public static class DFUtilities.NamedObjComparator
    extends java.lang.Object
    implements java.util.Comparator
    A comparator for named objects.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int compare​(java.lang.Object object1, java.lang.Object object2)
      Compare two objects.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Comparator

        equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
    • Constructor Detail

      • NamedObjComparator

        public NamedObjComparator()
    • Method Detail

      • compare

        public int compare​(java.lang.Object object1,
                           java.lang.Object object2)
        Compare two objects. If the objects are not NamedObjs, then an InternalErrorException is thrown.
        Specified by:
        compare in interface java.util.Comparator
        Parameters:
        object1 - The first object to be compared.
        object2 - The second object to be compared.
        Returns:
        0 if the objects are the same.