I have made the Date in in my java Class
and this is the code i have used in controller
@InitBinder
public void initBinder(final WebDataBinder binder) {
binder.registerCustomEditor(Date.class, null, new CustomDateEditor(new SimpleDateFormat("dd-MM-yyyy"), true));
}
i am usinng JSR annotations and hibernate to validate other fields.
Is there any way i can use annotations to validate that date must in dd-mm-yyyy format only