public String convertToValang(String fieldName, Annotation a, MessageSourceAccessor messages) {
String errMsg = "";
String applyIfValang = null;
if (a instanceof NotBlank) {
NotBlank annotation = (NotBlank) a;
errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
applyIfValang = valangToJS(annotation.applyIf());
} else if (a instanceof NotEmpty) {
NotEmpty annotation = (NotEmpty) a;
errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
applyIfValang = valangToJS(annotation.applyIf());
}
StringBuffer sb = new StringBuffer();
sb.append(" function() {return this.moreThan((this.lengthOf(this.getPropertyValue(");
sb.append(wrapAndEscapeJsString(fieldName));// field