class date comparator