cedric 2002/11/05 06:08:29
Modified: src/share/org/apache/struts/tiles TilesRequestProcessor.java
Log:
Add a method to retrieve associated factory
Revision Changes Path
1.9 +22 -6
jakarta-struts/src/share/org/apache/struts/tiles/TilesRequestProcessor.java
Index: TilesRequestProcessor.java
===================================================================
RCS file:
/home/cvs/jakarta-struts/src/share/org/apache/struts/tiles/TilesRequestProcessor.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- TilesRequestProcessor.java 18 Oct 2002 15:27:42 -0000 1.8
+++ TilesRequestProcessor.java 5 Nov 2002 14:08:29 -0000 1.9
@@ -81,6 +81,13 @@
* or include. When such call is done, Tiles processor check if the specified uri
* is a definition name. If true, the definition is retrieved and included. If
* false, the original uri is included or a forward is performed.
+ * <p>
+ * Actually, catching is done by overloading following methods:
+ * <ul>
+ * <li>{@link
#processForwardConfig(HttpServletRequest,HttpServletResponse,ForwardConfig)}</li>
+ * <li>{@link #internalModuleRelativeForward(String, HttpServletRequest ,
HttpServletResponse)}</li>
+ * <li>{@link #internalModuleRelativeInclude(String, HttpServletRequest ,
HttpServletResponse)}</li>
+ * </ul>
* </p>
* @author Cedric Dumoulin
* @since Tiles 1.1.1
@@ -89,10 +96,11 @@
{
/** Definitions factory */
private DefinitionsFactory definitionsFactory;
+
/**
* Commons Logging instance.
*/
- protected static Log log = LogFactory.getLog(RequestProcessor.class);
+ protected static Log log = LogFactory.getLog(TilesRequestProcessor.class);
/**
* Initialize this request processor instance.
@@ -146,7 +154,7 @@
* @return True if the method has process uri as a definition name, false
otherwise.
*/
protected boolean processTilesDefinition(String definitionName, boolean
contextRelative, HttpServletRequest request, HttpServletResponse response)
- throws IOException, ServletException
+ throws IOException, ServletException
{
//System.out.println("doForward(" + uri + ")");
// Do we do a forward (original behavior) or an include ?
@@ -252,7 +260,7 @@
* @param response Current page response
*/
protected void doForward(String uri, HttpServletRequest request,
HttpServletResponse response)
- throws IOException, ServletException
+ throws IOException, ServletException
{
if(response.isCommitted())
doInclude(uri, request, response);
@@ -347,5 +355,13 @@
super.internalModuleRelativeInclude(uri, request, response);
}
+
+ /**
+ * Get associated definition factory.
+ */
+ public DefinitionsFactory getDefinitionsFactory()
+ {
+ return definitionsFactory;
+ }
}
--
To unsubscribe, e-mail: <mailto:struts-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@;jakarta.apache.org>