ValidationUtils.rejectIfEmptyOrWhitespace(errors, "favNumber",
"required.favNumber", "Field name is required.");
ValidationUtils.rejectIfEmptyOrWhitespace(
errors, "javaSkills", "required.javaSkills","Field name is required.");
Customer cust = (Customer)target;
if(!(cust.getPassword().equals(cust.getConfirmPassword()))){
errors.rejectValue("password", "notmatch.password");
}
if(cust.getFavFramework().length==0){
errors.rejectValue("favFramework", "required.favFrameworks");
}
if("NONE".equals(cust.getCountry())){
errors.rejectValue("country", "required.country");
}
}