struts-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tm...@apache.org
Subject svn commit: r471448 - /struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java
Date Sun, 05 Nov 2006 15:51:18 GMT
Author: tmjee
Date: Sun Nov  5 07:51:17 2006
New Revision: 471448

URL: http://svn.apache.org/viewvc?view=rev&rev=471448
Log:
WW-1490 (Have a composite ActionMapper that decides which ActionMapper it contains should
be used)
 - added snippet, so we could use some of the javadoc in confluence
  - 


Modified:
    struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java

Modified: struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java
URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java?view=diff&rev=471448&r1=471447&r2=471448
==============================================================================
--- struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java
(original)
+++ struts/struts2/trunk/core/src/main/java/org/apache/struts2/dispatcher/mapper/CompositeActionMapper.java
Sun Nov  5 07:51:17 2006
@@ -35,18 +35,22 @@
 import com.opensymphony.xwork2.util.FileManager;
 
 /**
+ * <!-- START SNIPPET: description -->
+ * 
  * A composite action mapper that is capable of delegating to a series of {@link ActionMapper}
if the former 
  * failed to obtained a valid {@link ActionMapping} or uri.
  * <p/>
  * It is configured through struts.properties. 
  * <p/>
  * For example, with the following entries in struts.properties
+ * <p/>
  * <pre>
  * struts.mapper.class=org.apache.struts2.dispatcher.mapper.CompositeActionMapper
  * struts.mapper.composite.1=org.apache.struts2.dispatcher.mapper.DefaultActionMapper
  * struts.mapper.composite.2=org.apache.struts2.dispatcher.mapper.RestfulActionMapper
  * struts.mapper.composite.3=org.apache.struts2.dispatcher.mapper.Restful2ActionMapper
  * </pre>
+ * <p/>
  * When {@link CompositeActionMapper#getMapping(HttpServletRequest, ConfigurationManager)}
or 
  * {@link CompositeActionMapper#getUriFromActionMapping(ActionMapping)} is invoked, 
  * {@link CompositeActionMapper} would go through these {@link ActionMapper}s in sequence

@@ -56,8 +60,21 @@
  * in which case it will just return null for both 
  * {@link CompositeActionMapper#getMapping(HttpServletRequest, ConfigurationManager)} and

  * {@link CompositeActionMapper#getUriFromActionMapping(ActionMapping)} methods.
+ * <p/>
  * 
+ * For example with the following in struts.properties :-
+ * <pre>
+ * struts.mapper.class=org.apache.struts2.dispatcher.mapper.CompositeActionMapper
+ * struts.mapper.composite.1=org.apache.struts2.dispatcher.mapper.DefaultActionMapper
+ * struts.mapper.composite.2=foo.bar.MyActionMapper
+ * struts.mapper.composite.3=foo.bar.MyAnotherActionMapper
+ * </pre>
  * <p/>
+ * <code>CompositeActionMapper</code> will be configured with 3 ActionMapper,
namely
+ * "DefaultActionMapper", "MyActionMapper" and "MyAnotherActionMapper".  
+ * <code>CompositeActionMapper</code> would consult each of them in order described
above.
+ * 
+ * <!-- END SNIPPET: description -->
  * 
  * @see ActionMapper
  * @see ActionMapperFactory



Mime
View raw message