code: public static int numberAwareCompareTo(Comparable self, Comparable other) {
          NumberAwareComparator<Comparable> numberAwareComparator = new NumberAwareComparator<Comparable>();
          return numberAwareComparator.compare(self, other);
      }
docs: Provides a method that compares two comparables using Groovy's
  default number aware comparator.
  
  @param self a Comparable
  @param other another Comparable
  @return a -ve number, 0 or a +ve number according to Groovy's compareTo contract
  @since 1.6.0