| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| TurbineConstants |
|
| 0.0;0 |
| 1 | package org.apache.turbine; | |
| 2 | ||
| 3 | /* | |
| 4 | * Licensed to the Apache Software Foundation (ASF) under one | |
| 5 | * or more contributor license agreements. See the NOTICE file | |
| 6 | * distributed with this work for additional information | |
| 7 | * regarding copyright ownership. The ASF licenses this file | |
| 8 | * to you under the Apache License, Version 2.0 (the | |
| 9 | * "License"); you may not use this file except in compliance | |
| 10 | * with the License. You may obtain a copy of the License at | |
| 11 | * | |
| 12 | * http://www.apache.org/licenses/LICENSE-2.0 | |
| 13 | * | |
| 14 | * Unless required by applicable law or agreed to in writing, | |
| 15 | * software distributed under the License is distributed on an | |
| 16 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | |
| 17 | * KIND, either express or implied. See the License for the | |
| 18 | * specific language governing permissions and limitations | |
| 19 | * under the License. | |
| 20 | */ | |
| 21 | ||
| 22 | import org.apache.turbine.pipeline.TurbinePipeline; | |
| 23 | ||
| 24 | ||
| 25 | ||
| 26 | ||
| 27 | /** | |
| 28 | * This interface contains all the constants used throughout | |
| 29 | * the Turbine code base. | |
| 30 | * | |
| 31 | * @author <a href="mailto:jvanzyl@apache.org">Jason van Zyl</a> | |
| 32 | * @author <a href="mailto:hps@intermeta.de">Henning P. Schmiedehausen</a> | |
| 33 | * @author <a href="mailto:seade@backstagetech.com.au">Scott Eade</a> | |
| 34 | * @version $Id: TurbineConstants.java 1709648 2015-10-20 17:08:10Z tv $ | |
| 35 | */ | |
| 36 | public interface TurbineConstants | |
| 37 | { | |
| 38 | /** | |
| 39 | * <p>The prefix used to denote the namespace reserved for and | |
| 40 | * used by Turbine-specific configuration parameters (such as | |
| 41 | * those passed in via servlet container's config file | |
| 42 | * (<code>server.xml</code>), or the web app deployment descriptor | |
| 43 | * (<code>web.xml</code>).</p> | |
| 44 | * | |
| 45 | * <p>For example, a parameter in the Turbine namespace would be | |
| 46 | * <code>org.apache.turbine.loggingRoot</code>.</p> | |
| 47 | */ | |
| 48 | String CONFIG_NAMESPACE = "org.apache.turbine"; | |
| 49 | ||
| 50 | /** The key for the Log4J File */ | |
| 51 | String LOG4J_CONFIG_FILE = "log4j.file"; | |
| 52 | ||
| 53 | /** The default value for the Log4J File */ | |
| 54 | String LOG4J_CONFIG_FILE_DEFAULT = "/WEB-INF/conf/Log4j.properties"; | |
| 55 | ||
| 56 | /** This is the default log file to be used for logging */ | |
| 57 | String DEFAULT_LOGGER = "turbine"; | |
| 58 | ||
| 59 | /** The logging facility which captures output from the SchedulerService. */ | |
| 60 | String SCHEDULER_LOG_FACILITY = "scheduler"; | |
| 61 | ||
| 62 | /** The SMTP server Turbine uses to send mail. */ | |
| 63 | String MAIL_SERVER_KEY = "mail.server"; | |
| 64 | ||
| 65 | /** Default Value for he SMTP server that Turbine uses to send mail. */ | |
| 66 | String MAIL_SERVER_DEFAULT = "localhost"; | |
| 67 | ||
| 68 | /** The Smtp sender address property */ | |
| 69 | String MAIL_SMTP_FROM = "mail.smtp.from"; | |
| 70 | ||
| 71 | /** Property that controls whether Turbine modules are cached or not. */ | |
| 72 | String MODULE_CACHE_KEY = "module.cache"; | |
| 73 | ||
| 74 | /** Default value of the Turbine Module Caching */ | |
| 75 | boolean MODULE_CACHE_DEFAULT = true; | |
| 76 | ||
| 77 | /** Property that controls the module cache size. */ | |
| 78 | String MODULE_CACHE_SIZE_KEY = "module.cache.size"; | |
| 79 | ||
| 80 | /** Default value of the Turbine Module Cache Size */ | |
| 81 | int MODULE_CACHE_SIZE_DEFAULT = 128; | |
| 82 | ||
| 83 | /** The packages where Turbine will look for modules. */ | |
| 84 | String MODULE_PACKAGES = "module.packages"; | |
| 85 | ||
| 86 | /** Home page template. */ | |
| 87 | String TEMPLATE_HOMEPAGE = "template.homepage"; | |
| 88 | ||
| 89 | /** Login template. */ | |
| 90 | String TEMPLATE_LOGIN = "template.login"; | |
| 91 | ||
| 92 | /** Template error template Property. */ | |
| 93 | String TEMPLATE_ERROR_KEY = "template.error"; | |
| 94 | ||
| 95 | /** Template error default for JSP */ | |
| 96 | String TEMPLATE_ERROR_JSP = "error.jsp"; | |
| 97 | ||
| 98 | /** Template error default for Velocity */ | |
| 99 | String TEMPLATE_ERROR_VM = "error.vm"; | |
| 100 | ||
| 101 | /** Home page screen. */ | |
| 102 | String SCREEN_HOMEPAGE = "screen.homepage"; | |
| 103 | ||
| 104 | /** Login screen. */ | |
| 105 | String SCREEN_LOGIN = "screen.login"; | |
| 106 | ||
| 107 | /** Login error screen. */ | |
| 108 | String SCREEN_ERROR_KEY = "screen.error"; | |
| 109 | ||
| 110 | /** Default value for Login Screen */ | |
| 111 | String SCREEN_ERROR_DEFAULT = "VelocityErrorScreen"; | |
| 112 | ||
| 113 | /** Report Screen for invalid state in the application*/ | |
| 114 | String SCREEN_INVALID_STATE = "screen.invalidstate"; | |
| 115 | ||
| 116 | /** Report Template for invalid state in the application */ | |
| 117 | String TEMPLATE_INVALID_STATE = "template.invalidstate"; | |
| 118 | ||
| 119 | /** Action to perform when a user logs in. */ | |
| 120 | String ACTION_LOGIN_KEY = "action.login"; | |
| 121 | ||
| 122 | /** Default Value for login Action */ | |
| 123 | String ACTION_LOGIN_DEFAULT = "LoginUser"; | |
| 124 | ||
| 125 | /** Action to perform when a user logs out. */ | |
| 126 | String ACTION_LOGOUT_KEY = "action.logout"; | |
| 127 | ||
| 128 | /** Default Value for ACTION_LOGOUT */ | |
| 129 | String ACTION_LOGOUT_DEFAULT = "LogoutUser"; | |
| 130 | ||
| 131 | /** Actions that performs session validation. */ | |
| 132 | String ACTION_SESSION_VALIDATOR_KEY = "action.sessionvalidator"; | |
| 133 | ||
| 134 | /** Default value for the session validator. (org.apache.modules.actions.sessionvalidator.TemplateSessionValidator) */ | |
| 135 | String ACTION_SESSION_VALIDATOR_DEFAULT = "sessionvalidator.TemplateSessionValidator"; | |
| 136 | ||
| 137 | /** Action that performs Access control */ | |
| 138 | String ACTION_ACCESS_CONTROLLER_KEY = "action.accesscontroller"; | |
| 139 | ||
| 140 | /** Default value for the access controller. (org.apache.modules.actions.AccessController) */ | |
| 141 | String ACTION_ACCESS_CONTROLLER_DEFAULT = "AccessController"; | |
| 142 | ||
| 143 | /** Select whether an Action Event must have a non-zero value */ | |
| 144 | String ACTION_EVENTSUBMIT_NEEDSVALUE_KEY = "action.eventsubmit.needsvalue"; | |
| 145 | ||
| 146 | /** Default value for action.eventsubmit.needsvalue */ | |
| 147 | boolean ACTION_EVENTSUBMIT_NEEDSVALUE_DEFAULT = false; | |
| 148 | ||
| 149 | /** Select whether an exception in an Action method is bubbled up to Turbine.handleException() */ | |
| 150 | String ACTION_EVENT_BUBBLE_EXCEPTION_UP = "action.event.bubbleexception"; | |
| 151 | ||
| 152 | /** Default value for action.event.bubbleexception */ | |
| 153 | boolean ACTION_EVENT_BUBBLE_EXCEPTION_UP_DEFAULT = true; | |
| 154 | ||
| 155 | /** Default layout. */ | |
| 156 | String LAYOUT_DEFAULT = "layout.default"; | |
| 157 | ||
| 158 | /** Default page. */ | |
| 159 | String PAGE_DEFAULT_KEY = "page.default"; | |
| 160 | ||
| 161 | /** Default value for the Default Page */ | |
| 162 | String PAGE_DEFAULT_DEFAULT = "DefaultPage"; | |
| 163 | ||
| 164 | /** Default value for the Default Screen */ | |
| 165 | String SCREEN_DEFAULT_DEFAULT = "DefaultScreen"; | |
| 166 | ||
| 167 | /** Message to display upon successful login. */ | |
| 168 | String LOGIN_MESSAGE = "login.message"; | |
| 169 | ||
| 170 | /** Message to display when a user fails to login. */ | |
| 171 | String LOGIN_ERROR = "login.error"; | |
| 172 | ||
| 173 | /** Message to display when screens variable invalid. */ | |
| 174 | String LOGIN_MESSAGE_NOSCREEN = "login.message.noscreen"; | |
| 175 | ||
| 176 | /** Message to display when a user logs out. */ | |
| 177 | String LOGOUT_MESSAGE = "logout.message"; | |
| 178 | ||
| 179 | /** Session Timeout */ | |
| 180 | String SESSION_TIMEOUT_KEY = "session.timeout"; | |
| 181 | ||
| 182 | /** Session Timeout Default Value */ | |
| 183 | int SESSION_TIMEOUT_DEFAULT = -1; | |
| 184 | ||
| 185 | /** Indicate whether this Turbine application is using SSL. */ | |
| 186 | String USE_SSL_KEY = "use.ssl"; | |
| 187 | ||
| 188 | /** Default value for the SSL key */ | |
| 189 | boolean USE_SSL_DEFAULT = true; | |
| 190 | ||
| 191 | /** | |
| 192 | * Should the PP fold the case of everything. Possible values are | |
| 193 | * "upper", "lower" and "none". | |
| 194 | */ | |
| 195 | String PP_URL_CASE_FOLDING = "url.case.folding"; | |
| 196 | ||
| 197 | /** Default document type. */ | |
| 198 | String DEFAULT_DOCUMENT_TYPE_KEY = "default.doctype"; | |
| 199 | ||
| 200 | /** Default doctype root element. */ | |
| 201 | String DEFAULT_HTML_DOCTYPE_ROOT_ELEMENT_KEY | |
| 202 | = "default.html.doctype.root.element"; | |
| 203 | ||
| 204 | /** Default value for the doctype root element */ | |
| 205 | String DEFAULT_HTML_DOCTYPE_ROOT_ELEMENT_DEFAULT | |
| 206 | = "HTML"; | |
| 207 | ||
| 208 | /** Default doctype dtd. */ | |
| 209 | String DEFAULT_HTML_DOCTYPE_IDENTIFIER_KEY | |
| 210 | = "default.html.doctype.identifier"; | |
| 211 | ||
| 212 | /** Default Doctype dtd value */ | |
| 213 | String DEFAULT_HTML_DOCTYPE_IDENTIFIER_DEFAULT | |
| 214 | = "-//W3C//DTD HTML 4.01 Transitional//EN"; | |
| 215 | ||
| 216 | /** Default doctype url. */ | |
| 217 | String DEFAULT_HTML_DOCTYPE_URI_KEY | |
| 218 | = "default.html.doctype.url"; | |
| 219 | ||
| 220 | /** Default doctype url value. */ | |
| 221 | String DEFAULT_HTML_DOCTYPE_URI_DEFAULT | |
| 222 | = "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd"; | |
| 223 | ||
| 224 | /** Default Language property */ | |
| 225 | String LOCALE_DEFAULT_LANGUAGE_KEY = "locale.default.language"; | |
| 226 | ||
| 227 | /** Default value for Language property */ | |
| 228 | String LOCALE_DEFAULT_LANGUAGE_DEFAULT = "en"; | |
| 229 | ||
| 230 | /** Default Country property */ | |
| 231 | String LOCALE_DEFAULT_COUNTRY_KEY = "locale.default.country"; | |
| 232 | ||
| 233 | /** Default value for Country property */ | |
| 234 | String LOCALE_DEFAULT_COUNTRY_DEFAULT = "US"; | |
| 235 | ||
| 236 | /** Default Charset property */ | |
| 237 | String LOCALE_DEFAULT_CHARSET_KEY = "locale.default.charset"; | |
| 238 | ||
| 239 | /** Default value for Charset property */ | |
| 240 | String LOCALE_DEFAULT_CHARSET_DEFAULT = "ISO-8859-1"; | |
| 241 | ||
| 242 | /** If this value is set as applicationRoot, then the webContext is used | |
| 243 | * as application root | |
| 244 | */ | |
| 245 | String WEB_CONTEXT = "webContext"; | |
| 246 | ||
| 247 | /** Key for the Path to the TurbineResources.properties File */ | |
| 248 | String APPLICATION_ROOT_KEY = "applicationRoot"; | |
| 249 | ||
| 250 | /** Default Value for the Path to the TurbineResources.properties File */ | |
| 251 | String APPLICATION_ROOT_DEFAULT = WEB_CONTEXT; | |
| 252 | ||
| 253 | /** This is the key used in the Turbine.properties to access resources | |
| 254 | * relative to the Web Application root. It might differ from the | |
| 255 | * Application root, but the normal case is, that the webapp root | |
| 256 | * and the application root point to the same path. | |
| 257 | */ | |
| 258 | String WEBAPP_ROOT_KEY = "webappRoot"; | |
| 259 | ||
| 260 | /** The Key in the deployment descriptor for the Logging Directory */ | |
| 261 | String LOGGING_ROOT_KEY = "loggingRoot"; | |
| 262 | ||
| 263 | /** Default Value for the Logging Directory, relative to the webroot */ | |
| 264 | String LOGGING_ROOT_DEFAULT = "/logs"; | |
| 265 | ||
| 266 | /** Key for loading the UUID Generator with a constant value */ | |
| 267 | String UUID_ADDRESS_KEY = "uuid.address"; | |
| 268 | ||
| 269 | /** Context Key for the screen placeholder in the various velocity layouts */ | |
| 270 | String SCREEN_PLACEHOLDER = "screen_placeholder"; | |
| 271 | ||
| 272 | /** Context Key for the navigation object placeholder in the various velocity layouts */ | |
| 273 | String NAVIGATION_PLACEHOLDER = "navigation"; | |
| 274 | ||
| 275 | /** Context Key for the Processing Exception */ | |
| 276 | String PROCESSING_EXCEPTION_PLACEHOLDER = "processingException"; | |
| 277 | ||
| 278 | /** Context Key for the Stack Trace */ | |
| 279 | String STACK_TRACE_PLACEHOLDER = "stackTrace"; | |
| 280 | ||
| 281 | /** Encoding for Parameter Parser */ | |
| 282 | String PARAMETER_ENCODING_KEY = "input.encoding"; | |
| 283 | ||
| 284 | /** Default Encoding for Parameter Parser */ | |
| 285 | String PARAMETER_ENCODING_DEFAULT = "ISO-8859-1"; | |
| 286 | ||
| 287 | /** Default serverName for ServerData */ | |
| 288 | String DEFAULT_SERVER_NAME_KEY | |
| 289 | = "serverdata.default.serverName"; | |
| 290 | ||
| 291 | /** Default serverPort for ServerData */ | |
| 292 | String DEFAULT_SERVER_PORT_KEY | |
| 293 | = "serverdata.default.serverPort"; | |
| 294 | ||
| 295 | /** Default serverScheme for ServerData */ | |
| 296 | String DEFAULT_SERVER_SCHEME_KEY | |
| 297 | = "serverdata.default.serverScheme"; | |
| 298 | ||
| 299 | /** Default scriptName for ServerData */ | |
| 300 | String DEFAULT_SCRIPT_NAME_KEY | |
| 301 | = "serverdata.default.scriptName"; | |
| 302 | ||
| 303 | /** Default contextPath for ServerData */ | |
| 304 | String DEFAULT_CONTEXT_PATH_KEY | |
| 305 | = "serverdata.default.contextPath"; | |
| 306 | ||
| 307 | /** The default Session key for the Access Control List */ | |
| 308 | String ACL_SESSION_KEY = "turbine.AccessControlList"; | |
| 309 | ||
| 310 | /** | |
| 311 | * The fully qualified class name of the default {@link | |
| 312 | * org.apache.turbine.pipeline.Pipeline} implementation to use in the | |
| 313 | * {@link org.apache.turbine.Turbine} servlet. | |
| 314 | */ | |
| 315 | String STANDARD_PIPELINE = TurbinePipeline.class.getName(); | |
| 316 | } |