KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > struts > Globals


1 /*
2  * $Id: Globals.java 54929 2004-10-16 16:38:42Z germuska $
3  *
4  * Copyright 2000-2004 The Apache Software Foundation.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */

18
19 package org.apache.struts;
20
21 import java.io.Serializable JavaDoc;
22
23 /**
24  * Global manifest constants for the entire Struts Framework.
25  *
26  * @version $Rev: 54929 $ $Date: 2004-10-16 17:38:42 +0100 (Sat, 16 Oct 2004) $
27  */

28 public class Globals implements Serializable JavaDoc {
29
30
31     // ----------------------------------------------------- Manifest Constants
32

33
34     /**
35      * The context attributes key under which our <code>ActionServlet</code>
36      * instance will be stored.
37      *
38      * @since Struts 1.1
39      */

40     public static final String JavaDoc ACTION_SERVLET_KEY =
41         "org.apache.struts.action.ACTION_SERVLET";
42
43     /**
44      * The request attributes key under which a boolean <code>true</code>
45      * value should be stored if this request was cancelled.
46      *
47      * @since Struts 1.1
48      */

49     public static final String JavaDoc CANCEL_KEY =
50         "org.apache.struts.action.CANCEL";
51
52     /**
53      * <p>The base of the context attributes key under which our
54      * <code>ModuleConfig</code> data structure will be stored. This
55      * will be suffixed with the actual module prefix (including the
56      * leading "/" character) to form the actual attributes key.</p>
57      *
58      * <p>For each request processed by the controller servlet, the
59      * <code>ModuleConfig</code> object for the module selected by
60      * the request URI currently being processed will also be exposed under
61      * this key as a request attribute.</p>
62      *
63      * @since Struts 1.1
64      */

65     public static final String JavaDoc MODULE_KEY =
66         "org.apache.struts.action.MODULE";
67         
68     /**
69      * The ServletContext attribute under which we store the module prefixes
70      * String[].
71      * @since Struts 1.2
72      */

73     public static final String JavaDoc MODULE_PREFIXES_KEY =
74         "org.apache.struts.globals.MODULE_PREFIXES";
75
76
77     /**
78      * The context attributes key under which our <strong>default</strong>
79      * configured data source (which must implement
80      * <code>javax.sql.DataSource</code>) is stored,
81      * if one is configured for this module.
82      */

83     public static final String JavaDoc DATA_SOURCE_KEY =
84       "org.apache.struts.action.DATA_SOURCE";
85
86
87     /**
88      * The request attributes key under which your action should store an
89      * <code>org.apache.struts.action.ActionErrors</code> object, if you
90      * are using the corresponding custom tag library elements.
91      */

92     public static final String JavaDoc ERROR_KEY =
93       "org.apache.struts.action.ERROR";
94
95     /**
96      * The request attributes key under which Struts custom tags might store a
97      * <code>Throwable</code> that caused them to report a JspException at
98      * runtime. This value can be used on an error page to provide more
99      * detailed information about what really went wrong.
100      */

101     public static final String JavaDoc EXCEPTION_KEY =
102         "org.apache.struts.action.EXCEPTION";
103
104     /**
105      * The session attributes key under which the user's selected
106      * <code>java.util.Locale</code> is stored, if any. If no such
107      * attribute is found, the system default locale
108      * will be used when retrieving internationalized messages. If used, this
109      * attribute is typically set during user login processing.
110      */

111     public static final String JavaDoc LOCALE_KEY =
112       "org.apache.struts.action.LOCALE";
113
114     /**
115      * The request attributes key under which our
116      * <code>org.apache.struts.ActionMapping</code> instance
117      * is passed.
118      */

119     public static final String JavaDoc MAPPING_KEY =
120         "org.apache.struts.action.mapping.instance";
121
122     /**
123      * The request attributes key under which your action should store an
124      * <code>org.apache.struts.action.ActionMessages</code> object, if you
125      * are using the corresponding custom tag library elements.
126      *
127      * @since Struts 1.1
128      */

129     public static final String JavaDoc MESSAGE_KEY =
130       "org.apache.struts.action.ACTION_MESSAGE";
131
132
133     /**
134      * <p>The base of the context attributes key under which our
135      * module <code>MessageResources</code> will be stored. This
136      * will be suffixed with the actual module prefix (including the
137      * leading "/" character) to form the actual resources key.</p>
138      *
139      * <p>For each request processed by the controller servlet, the
140      * <code>MessageResources</code> object for the module selected by
141      * the request URI currently being processed will also be exposed under
142      * this key as a request attribute.</p>
143      */

144     public static final String JavaDoc MESSAGES_KEY =
145       "org.apache.struts.action.MESSAGE";
146
147
148     /**
149      * The request attributes key under which our multipart class is stored.
150      */

151     public static final String JavaDoc MULTIPART_KEY =
152         "org.apache.struts.action.mapping.multipartclass";
153
154
155     /**
156      * <p>The base of the context attributes key under which an array of
157      * <code>PlugIn</code> instances will be stored. This
158      * will be suffixed with the actual module prefix (including the
159      * leading "/" character) to form the actual attributes key.</p>
160      * @since Struts 1.1
161      */

162     public static final String JavaDoc PLUG_INS_KEY =
163         "org.apache.struts.action.PLUG_INS";
164
165
166     /**
167      * <p>The base of the context attributes key under which our
168      * <code>RequestProcessor</code> instance will be stored. This
169      * will be suffixed with the actual module prefix (including the
170      * leading "/" character) to form the actual attributes key.</p>
171      * @since Struts 1.1
172      */

173     public static final String JavaDoc REQUEST_PROCESSOR_KEY =
174         "org.apache.struts.action.REQUEST_PROCESSOR";
175
176
177     /**
178      * The context attributes key under which we store the mapping defined
179      * for our controller serlet, which will be either a path-mapped pattern
180      * (<code>/action/*</code>) or an extension mapped pattern
181      * (<code>*.do</code>).
182      */

183     public static final String JavaDoc SERVLET_KEY =
184         "org.apache.struts.action.SERVLET_MAPPING";
185
186
187     /**
188      * The session attributes key under which our transaction token is
189      * stored, if it is used.
190      */

191     public static final String JavaDoc TRANSACTION_TOKEN_KEY =
192         "org.apache.struts.action.TOKEN";
193         
194     /**
195      * The page attributes key under which xhtml status is stored. This may be "true"
196      * or "false". When set to true, the html tags output xhtml.
197      * @since Struts 1.1
198      */

199     public static final String JavaDoc XHTML_KEY =
200         "org.apache.struts.globals.XHTML";
201
202
203 }
204
Popular Tags