struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Don Brown <mr...@twdata.org>
Subject [ANN] Wildcard-Matched Actions
Date Sun, 08 Jun 2003 07:01:14 GMT
This project allows wildcards to be used in Struts 1.1+ action mappings. The 
wildcard-matched values can then be substituted in the values of various 
Struts action mapping and action forward attributes. It uses the wildcard 
matching class from Apache Cocoon which is the default matching class used to 
match XML transformation pipelines.

The bottom line of this project is you can write generic actions that can be 
used to match multiple actions. Even the "type" attribute which specifies the 
Action class can have wildcard-matched values substituted to match multiple 
Action classes for one action mapping. It also works great for Struts 
applications that use DispatchActions or other generic Actions.

For example:
        <action    path="/edit*"
                   type="org.twdata.struts.ScriptAction"
              attribute="{1}Form"
                  scope="request"
               validate="false"
              parameter="/WEB-INF/scripts/Edit{1}.bsh">
           
            <forward name="failure"              path="/mainMenu.jsp"/>
            <forward name="success"              path="/{1}.jsp"/>
        </action>

Project page:  http://www.twdata.org/struts-wildcard/

Comments and suggestions always welcome.

Don

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


Mime
View raw message