code: protected <S extends Serializable> void validateDomainObject(S domainObject, Set<ATError> errors) {
  		Set<ConstraintViolation<S>> constraintViolations = validator.validate( domainObject );
  		if (CollectionUtils.isEmpty(constraintViolations)) {
  			return;
  		}
  		for ( ConstraintViolation<S> violation : constraintViolations ) {
  			String type = violation.getConstraintDescriptor().getAnnotation().annotationType().getSimpleName();
  			String attrPath = violation.getPropertyPath().toString();
  			String msgKey = attrPath + "." + type;
  			if (null != violation.getMessage() && violation.getMessage().startsWith(MSG_KEY_PREFIX)) {
  				msgKey = violation.getMessage();
  			}
  			errors.add(new ATError((attrPath + "." + type), getMessage(msgKey, new Object[]{attrPath}, violation.getMessage()), attrPath));
  		}
  	}
docs: validates a domain object with javax.validation annotations
  
  @param domainObject
  @param errors