KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > opensymphony > webwork > WebWorkStatics


1 /*
2  * Copyright (c) 2002-2003 by OpenSymphony
3  * All rights reserved.
4  */

5 package com.opensymphony.webwork;
6
7
8 /**
9  * Constants used by WebWork. The constants can be used to get or set objects out of the action context
10  * or other collections.<p>
11  * <p/>
12  * Example:
13  * <ul><code>ActionContext.getContext().put(HTTP_REQUEST, request);</code></ul>
14  * <p/>
15  * or
16  * <p/>
17  * <ul><code>
18  * ActionContext context = ActionContext.getContext();<br>
19  * HttpServletRequest request = (HttpServletRequest)context.get(HTTP_REQUEST);</code></ul>
20  *
21  * @author Patrick Lightbody
22  * @author Bill Lynch (docs)
23  */

24 public interface WebWorkStatics {
25     //~ Static fields/initializers /////////////////////////////////////////////
26

27     /**
28      * Constant for the HTTP request object.
29      */

30     public static final String JavaDoc HTTP_REQUEST = "com.opensymphony.xwork.dispatcher.HttpServletRequest";
31
32     /**
33      * Constant for the HTTP response object.
34      */

35     public static final String JavaDoc HTTP_RESPONSE = "com.opensymphony.xwork.dispatcher.HttpServletResponse";
36
37     /**
38      * Constant for an HTTP {@link javax.servlet.RequestDispatcher request dispatcher}.
39      */

40     public static final String JavaDoc SERVLET_DISPATCHER = "com.opensymphony.xwork.dispatcher.ServletDispatcher";
41
42     /**
43      * Constant for the {@link javax.servlet.ServletContext servlet context} object.
44      */

45     public static final String JavaDoc SERVLET_CONTEXT = "com.opensymphony.xwork.dispatcher.ServletContext";
46
47     /**
48      * Constant for the JSP {@link javax.servlet.jsp.PageContext page context}.
49      */

50     public static final String JavaDoc PAGE_CONTEXT = "com.opensymphony.xwork.dispatcher.PageContext";
51 }
52
Popular Tags