Package org.openfaces.validator

Examples of org.openfaces.validator.RequiredClientValidator


     * @return client validator
     */
    public ClientValidator getValidator(Annotation annotation) {
        Class<? extends Annotation> annotationClass = annotation.annotationType();
        if (annotationClass.equals(NotNull.class)) {
            return new RequiredClientValidator();
        } else if (annotationClass.equals(NotEmpty.class)) {
            return new RequiredClientValidator();
        } else if (annotationClass.equals(Email.class)) {
            return new EMailValidator();
        } else if (annotationClass.equals(Length.class)) {
            Length length = (Length) annotation;
            LengthValidator lengthValidator = new LengthValidator();
View Full Code Here


    }

    public List<ClientValidator> getClientValidators() {
        List<ClientValidator> clientValidators = new ArrayList<ClientValidator>();
        if (required)
            clientValidators.add(new RequiredClientValidator());

        if (converter != null) {
            ClientValidator clientValidator = ClientValidatorUtil.getClientValidator(converter, getComponent());
            if (clientValidator != null)
                clientValidators.add(clientValidator);
View Full Code Here

TOP

Related Classes of org.openfaces.validator.RequiredClientValidator

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.