@Override public int compare(Date o1, Date o2) {
        if (o1 == null) {
            return (o2 == null) ? 0 : -1;
        }

        if (o2 == null) {
            return 1;
        }

        long diff = diff(o1, o2);

        return (diff == 0) ? 0 : ((diff > 0) ? 1 : -1);
    }
@Override public int compare(Date o1, Date o2)