245246247248249250251252253254255
public void validateConvertedValue(FacesContext facesContext, Object value) { Validator validator = getValidator(); if (validator!=null) { validator.validate( facesContext, facesContext.getViewRoot(), value ); } if (valueExpression!=null && validateModel) { //TODO: note that this code is duplicated from ModelValidator!!
420421422423424425426427428429430
while (validators.hasNext()) { Validator validator = validators.next(); try { validator.validate(context, this, newValue); } catch (ValidatorException ve) { // If the validator throws an exception, we're // invalid, and we need to add a message
340341342343344345346347348349350
236237238239240241242243244245246
301302303304305306307308309310311
147148149150151152153154155156157
for (int i = 0; i < values.length; i++) { if (values[i].trim().length() == 0) { continue; } else try { validator.validate(facesContext, uiComponent, values[i]); } catch (ValidatorException e) { facesMsg = addMessage(facesMsg, e.getFacesMessage(), i, suffixMessageKey); } }
253254255256257258259260261262263
for (int i = 0; i < validators.length; i++) { Validator validator = validators[i]; try { validator.validate(context, input, convertedValue); } catch (ValidatorException e) { input.setValid(false);
267268269270271272273274275276277
156157158159160161162163164165166