SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy");
Date strDate = sdf.parse(my_date);
if (new Date().after(strDate)) {
your_date_is_outdated = true;
}
else{
your_date_is_outdated = false;
}
Date date1 = calendar1.getTime();
Date date2 = calendar2.getTime();
if (date1.compareTo(date2) > 0)
{ Log.i("app", "Date1 is after Date2");}
else if (date1.compareTo(date2) < 0)
{ Log.i("app", "Date1 is before Date2");}
else if (date1.compareTo(date2) == 0)
{ Log.i("app", "Date1 is equal to Date2");}