struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dgra...@apache.org
Subject cvs commit: jakarta-struts/doc/userGuide dev_validator.xml
Date Sat, 10 May 2003 15:27:53 GMT
dgraham     2003/05/10 08:27:53

  Modified:    doc/userGuide dev_validator.xml
  Log:
  Fixed pluggable validator example for PR# 19715.
  
  Revision  Changes    Path
  1.35      +30 -17    jakarta-struts/doc/userGuide/dev_validator.xml
  
  Index: dev_validator.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-struts/doc/userGuide/dev_validator.xml,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- dev_validator.xml	9 May 2003 00:47:03 -0000	1.34
  +++ dev_validator.xml	10 May 2003 15:27:53 -0000	1.35
  @@ -357,15 +357,24 @@
   
   <pre><code><![CDATA[
   <validator name="required"
  -     classname="org.apache.struts.validator.validator.FieldChecks"
  -     method="validateRequired"
  -     msg="errors.required"/>
  +        classname="org.apache.struts.validator.FieldChecks"
  +        method="validateRequired"
  +        methodParams="java.lang.Object,
  +                 org.apache.commons.validator.ValidatorAction,
  +                 org.apache.commons.validator.Field,
  +                 org.apache.struts.action.ActionErrors,
  +                 javax.servlet.http.HttpServletRequest"
  +        msg="errors.required">
   
   <validator name="mask"
  -     classname="org.apache.struts.validator.validator.FieldChecks"
  -     method="validateMask"
  -     depends="required"
  -     msg="errors.invalid"/>
  +        classname="org.apache.struts.validator.FieldChecks"
  +        method="validateMask"
  +        methodParams="java.lang.Object,
  +                 org.apache.commons.validator.ValidatorAction,
  +                 org.apache.commons.validator.Field,
  +                 org.apache.struts.action.ActionErrors,
  +                 javax.servlet.http.HttpServletRequest"
  +        msg="errors.invalid">
   ]]></code></pre>
   
       <p>
  @@ -373,18 +382,12 @@
       </p>
   
       <p>
  -    The ValidatorAction method needs to have the following signature.
  +    The <code>methodParams</code> attribute takes a comma separated list
  +    of class names. The <code>method</code> attribute needs to have a signature
  +    complying with the above list. The list can be comprised of any combination
  +    of the following:
       </p>
   
  -<pre><code><![CDATA[
  -(java.lang.Object,
  - org.apache.commons.validator.ValidatorAction,
  - org.apache.commons.validator.Field,
  - org.apache.struts.action.ActionErrors,
  - javax.servlet.http.HttpServletRequest,
  - javax.servlet.ServletContext)
  -]]></code></pre>
  -
       <ul>
   
           <li>
  @@ -415,6 +418,16 @@
           <li>
           <code>javax.servlet.ServletContext</code>
           - The application's ServletContext.
  +        </li>
  +
  +        <li>
  +        <code>org.apache.commons.validator.Validator</code>
  +        - The current org.apache.commons.validator.Validator instance.
  +        </li>
  +
  +        <li>
  +        <code>java.util.Locale</code>
  +        - The Locale of the current user.
           </li>
   
       </ul>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org


Mime
View raw message