Class NumberAwareComparator<T>

  • All Implemented Interfaces:
    Serializable, Comparator<T>

    public class NumberAwareComparator<T>
    extends Object
    implements Comparator<T>, Serializable
    Compares two objects using Groovy's friendly comparison algorithm, i.e. handles nulls gracefully (nul being less than everything else) and performs numeric type coercion if required.
    See Also:
    Serialized Form
    • Constructor Detail

      • NumberAwareComparator

        public NumberAwareComparator()
      • NumberAwareComparator

        public NumberAwareComparator​(boolean ignoreZeroSign)
        Since:
        3.0.8