code: @SuppressWarnings("unchecked")
    public int compare(Object arg0, Object arg1) {
      Object what0 = null;
      Object what1 = null;
      // 取出属性
      if (index > -1) {
        arg0 = ((Object[]) arg0)[index];
        arg1 = ((Object[]) arg1)[index];
        if (Strings.isEmpty(cmpWhat)) {
          what0 = arg0;
          what1 = arg1;
        }
      }
      if (Strings.isNotEmpty(cmpWhat)) {
        what0 = PropertyUtils.getProperty(arg0, cmpWhat);
        what1 = PropertyUtils.getProperty(arg1, cmpWhat);
      }
  
      if (what0 == null && null == what1) { return 0; }
  
      // 进行比较
      if (null == comparator) {
        if (what0 == null && null != what1) { return asc && nullFirst ? -1 : 1; }
  
        if (what0 != null && null == what1) { return asc && nullFirst ? 1 : -1; }
        // 进行字符串比较
        if (what0 instanceof String || what1 instanceof String) {
          return stringComparator.compare(what0.toString(), what1.toString());
        } else {
          if (asc) {
            return ((Comparable<Object>) what0).compareTo(what1);
          } else {
            return ((Comparable<Object>) what1).compareTo(what0);
          }
        }
      } else {
        // return doCompare(comparator,what0,what1);
        return comparator.compare(what0, what1);
      }
    }
docs: {@inheritDoc}