Package com.sun.faces.config.beans

Examples of com.sun.faces.config.beans.ValidatorBean


                                       digester.getMatch() +
                                       "} Push " + CLASS_NAME);
        }
        Class clazz =
            digester.getClassLoader().loadClass(CLASS_NAME);
        ValidatorBean vb = (ValidatorBean) clazz.newInstance();
        digester.push(vb);

    }


     * @exception IllegalStateException if the popped object is not
     *  of the correct type
     */
    public void end(String namespace, String name) throws Exception {

        ValidatorBean top = null;
        try {
            top = (ValidatorBean) digester.pop();
        } catch (Exception e) {
            throw new IllegalStateException("Popped object is not a " +
                                            CLASS_NAME + " instance");
        }
        FacesConfigBean fcb = (FacesConfigBean) digester.peek();
        ValidatorBean old = fcb.getValidator(top.getValidatorId());
        if (old == null) {
            if (digester.getLogger().isDebugEnabled()) {
                digester.getLogger().debug("[ValidatorRule]{" +
                                           digester.getMatch() +
                                           "} New(" +

        /*
         * Wrap these in braces to allow repetition of the ivar name
         */
        {
            ValidatorBean validator = new ValidatorBean();
            validator.setValidatorId("javax.faces.DoubleRange");
            validator.setValidatorClass("javax.faces.validator.DoubleRangeValidator");
            validators.add(validator);
        }
        {
            ValidatorBean validator = new ValidatorBean();
            validator.setValidatorId("javax.faces.Length");
            validator.setValidatorClass("javax.faces.validator.LengthValidator");
            validators.add(validator);
        }
        {
            ValidatorBean validator = new ValidatorBean();
            validator.setValidatorId("javax.faces.LongRange");
            validator.setValidatorClass("javax.faces.validator.LongRangeValidator");
            validators.add(validator);
        }

        /*
         * Wrap these in braces to allow repetition of the ivar name

                                       digester.getMatch() +
                                       "} Push " + CLASS_NAME);
        }
        Class clazz =
            digester.getClassLoader().loadClass(CLASS_NAME);
        ValidatorBean vb = (ValidatorBean) clazz.newInstance();
        digester.push(vb);

    }

     * @exception IllegalStateException if the popped object is not
     *  of the correct type
     */
    public void end(String namespace, String name) throws Exception {

        ValidatorBean top = null;
        try {
            top = (ValidatorBean) digester.pop();
        } catch (Exception e) {
            throw new IllegalStateException("Popped object is not a " +
                                            CLASS_NAME + " instance");
        }
        FacesConfigBean fcb = (FacesConfigBean) digester.peek();
        ValidatorBean old = fcb.getValidator(top.getValidatorId());
        if (old == null) {
            if (digester.getLogger().isDebugEnabled()) {
                digester.getLogger().debug("[ValidatorRule]{" +
                                           digester.getMatch() +
                                           "} New(" +

TOP

Related Classes of com.sun.faces.config.beans.ValidatorBean

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.