struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From craig...@apache.org
Subject cvs commit: jakarta-struts/src/share/org/apache/struts/action DynaActionFormClass.java
Date Tue, 23 Jul 2002 01:02:52 GMT
craigmcc    2002/07/22 18:02:52

  Modified:    src/share/org/apache/struts/action DynaActionFormClass.java
  Log:
  Make it possible to retrieve a previously configured DynaActionFormClass
  instance with the specified name.  TODO:  ensure that all possible dynamic
  form beans have had this done at startup time, instead of waiting for the
  first time a particular dynamic form is requested.
  
  Revision  Changes    Path
  1.8       +26 -4     jakarta-struts/src/share/org/apache/struts/action/DynaActionFormClass.java
  
  Index: DynaActionFormClass.java
  ===================================================================
  RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/action/DynaActionFormClass.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- DynaActionFormClass.java	13 Jul 2002 18:05:05 -0000	1.7
  +++ DynaActionFormClass.java	23 Jul 2002 01:02:51 -0000	1.8
  @@ -321,6 +321,28 @@
       }
   
   
  +    /**
  +     * Return an existing <code>DynaActionFormClass</code> of the specified
  +     * name, if one has been configured previously.  If no such instance has
  +     * been configured, return <code>null</code> instead.
  +     *
  +     * @param name Name of the <code>DynaActionFormClass</code> to be
  +     *  returned
  +     */
  +    public static DynaActionFormClass
  +        getDynaActionFormClass(String name) {
  +
  +        synchronized (lock) {
  +            if (dynaClasses == null) {
  +                return (null);
  +            } else {
  +                return ((DynaActionFormClass) dynaClasses.get(name));
  +            }
  +        }
  +
  +    }
  +
  +
       // ------------------------------------------------------ Protected Methods
   
   
  
  
  

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


Mime
View raw message