public void _validate(ValidationContext result) { validateValues(result); validateNameSpace(result); if ((_isNew() || isidentityChanged()) && (DataUtil.equals(getIdentity(), null))) { result.addError("identity", messages().required("Value")); } else { validateIdentity(result); } if (_has(VALUES)) { result.validateReference("values", getValues()); } _validateUniqueSettings(result); }
public void validateNameSpace(ValidationContext result) { if ((!DataUtil.equals(getNameSpace(), null)) && (getNameSpace().length() > 255)) { result.addError("nameSpace", "Length is exceed, You should enter 255 characters only"); } }
public void validateIdentity(ValidationContext result) { if (!NumberUtils.isValidIdentifier(getIdentity())) { result.addError("identity", "Identifier does not allow special characters"); } }
public void validateValues(ValidationContext result) { if (_has(VALUES)) { result.validateChilds("Values", getValues()); } }