ContentVersionBean bean = new ContentVersionBean(contentType, contentVersionVO, languageCode);
ValidatorResources resources = loadResources(contentType, languageCode);
Validator validator = new Validator(resources, "requiredForm");
validator.setOnlyReturnErrors(true);
validator.setParameter(Validator.BEAN_PARAM, bean);
ValidatorResults results = validator.validate();
if(results.isEmpty())
return new ConstraintExceptionBuffer();
else
return populateConstraintExceptionBuffer(results, contentVersionVO, languageCode);
} catch(Exception e) {
return new ConstraintExceptionBuffer();