blob: 776bb2cd518d467a4697fc44ef2a9b8460dc82d4 [file] [log] [blame]
Index: JspService.java
===================================================================
RCS file: /home/cvspublic/jakarta-turbine-2/src/java/org/apache/turbine/services/jsp/JspService.java,v
retrieving revision 1.3
diff -u -r1.3 JspService.java
--- JspService.java 11 Jan 2003 18:42:33 -0000 1.3
+++ JspService.java 11 Feb 2003 14:18:55 -0000
@@ -57,12 +57,13 @@
import org.apache.turbine.services.Service;
import org.apache.turbine.util.RunData;
import org.apache.turbine.util.TurbineException;
-
+import org.apache.velocity.context.Context;
/**
* Implementations of the JspService interface.
*
* @author <a href="mailto:john.mcnally@clearink.com">John D. McNally</a>
+ * @author <a href="mailto:gabrielm@itcsoluciones.com">Gabriel A. Moreno</a>
*/
public interface JspService extends Service
{
@@ -72,9 +73,14 @@
static final String RUNDATA = "rundata";
/** The key used to store an instance of JspLink in the request */
static final String LINK = "link";
+ /** The key used to store an instance of Context in the request */
+ static final String CONTEXT_INSTANCE = "context";
+ /** The key used to store an instance of Context in RunData */
+ static final String CONTEXT = "JSP_CONTEXT";
/**
- * Adds some useful objects to the request, so they are available to the JSP.
+ * Adds some useful objects to the request, so they are available
+ * to the JSP.
*/
void addDefaultObjects(RunData data);
@@ -105,4 +111,19 @@
*/
String getRelativeTemplateName(String template);
+ /**
+ * Create an empty WebContext object.
+ *
+ * @return An empty WebContext object.
+ */
+ Context getContext();
+
+ /**
+ * Create a Context from the RunData object.
+ *
+ * @param data The Turbine RunData object.
+ * @return A clone of the Context
+ */
+ Context getContext(RunData data);
+
}