All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.commons.validator.digester-rules.xml Maven / Gradle / Ivy

Go to download

Apache Commons Validator provides the building blocks for both client side validation and server side data validation. It may be used standalone or with a framework like Struts.

There is a newer version: 1.8.0
Show newest version
<?xml version="1.0"?>
<!--
 Licensed to the Apache Software Foundation (ASF) under one or more
 contributor license agreements.  See the NOTICE file distributed with
 this work for additional information regarding copyright ownership.
 The ASF licenses this file to You under the Apache License, Version 2.0
 (the "License"); you may not use this file except in compliance with
 the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.
-->

<!--
    digester-rules.xml defines the rules our Digester will use to transform 
    validation.xml files into Java objects.
    
    $Id$
-->


<!DOCTYPE digester-rules PUBLIC "-//Jakarta Apache //DTD digester-rules XML V1.0//EN" 
    "http://jakarta.apache.org/commons/digester/dtds/digester-rules.dtd">

<digester-rules>

    <pattern value="form-validation/global">
        
        <pattern value="constant">
            <call-method-rule methodname="addConstant" paramcount="2" />
            <call-param-rule pattern="constant-name" paramnumber="0" />
            <call-param-rule pattern="constant-value" paramnumber="1" />
        </pattern>
        
        <pattern value="validator">
            <object-create-rule classname="org.apache.commons.validator.ValidatorAction" />
            <set-properties-rule/>
            <set-next-rule methodname="addValidatorAction" paramtype="org.apache.commons.validator.ValidatorAction" />
            <call-method-rule pattern="javascript" methodname="setJavascript" paramcount="0" />
        </pattern>
        
    </pattern>
    
    
    <pattern value="form-validation/formset">

        <factory-create-rule classname="org.apache.commons.validator.FormSetFactory" />
        
        <pattern value="constant">
            <call-method-rule methodname="addConstant" paramcount="2" />
            <call-param-rule pattern="constant-name" paramnumber="0" />
            <call-param-rule pattern="constant-value" paramnumber="1" />
        </pattern>
        
        <pattern value="form">
            <object-create-rule classname="org.apache.commons.validator.Form" />
            <set-properties-rule/>
            <set-next-rule methodname="addForm" paramtype="org.apache.commons.validator.Form" />
            
            <pattern value="field">
                <object-create-rule classname="org.apache.commons.validator.Field" />
                <set-properties-rule/>
                <set-next-rule methodname="addField" paramtype="org.apache.commons.validator.Field" />
                
                <pattern value="var">
                    <object-create-rule classname="org.apache.commons.validator.Var" />
                    <set-properties-rule/>
                    <pattern value="var-name">
                        <call-method-rule methodname="setName" paramcount="0" />
                    </pattern>
                    <pattern value="var-value">
                        <call-method-rule methodname="setValue" paramcount="0" />
                    </pattern>
                    <pattern value="var-jstype">
                        <call-method-rule methodname="setJsType" paramcount="0" />
                    </pattern>
                    <set-next-rule methodname="addVar" paramtype="org.apache.commons.validator.Var" />
                </pattern>
                
                <pattern value="msg">
                    <object-create-rule classname="org.apache.commons.validator.Msg" />
                    <set-properties-rule/>
                    <set-next-rule methodname="addMsg" paramtype="org.apache.commons.validator.Msg" />
                </pattern>
                
                <pattern value="arg">
                    <object-create-rule classname="org.apache.commons.validator.Arg" />
                    <set-properties-rule/>
                    <set-next-rule methodname="addArg" paramtype="org.apache.commons.validator.Arg" />
                </pattern>
            
            </pattern>
            
        </pattern>
        
    </pattern>
</digester-rules>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy