Package org.crank.validation

Examples of org.crank.validation.ValidatorMessageHolder


        validateErrorsPresent(validator, "123", 1);
        validateErrorsPresent(validator, "foo", 1);
    }

    private void validateErrorsPresent(FieldValidator validator, String value, final int expectedValidationErrors) {
        ValidatorMessageHolder messages = validator.validate(value, "");
        int errors = 0;
        if (messages instanceof ValidatorMessages) {
             errors = errorCount((ValidatorMessages) messages);
        } else {
            if ( ((ValidatorMessage) messages).hasError()) {
View Full Code Here


     */
    FieldValidator validator = findValidatorAndFieldName(facesContext,
        component, fieldNameHolder);

    /* Validate the field. */
    ValidatorMessageHolder message = validator.validate(
        fieldValueToValidate, fieldNameHolder[0]);

    convertMessageToFacesMessages(message, facesContext, component);
       
        cleanup();
View Full Code Here

TOP

Related Classes of org.crank.validation.ValidatorMessageHolder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.