class ModifiedDateComparator implements Comparator<BaseEntity> {

    @Override
    public int compare(BaseEntity o1, BaseEntity o2) {
        if (order == SortOrder.ASCENDING) {
            return o1.getModified().compareTo(o2.getModified());
        } else {
            return o2.getModified().compareTo(o1.getModified());
        }
    }

    public  ModifiedDateComparator();
    public  ModifiedDateComparator(SortOrder order);

}