Source Code Cross Referenced for PullService.java in  » Web-Framework » TURBINE » org » apache » turbine » services » pull » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Framework » TURBINE » org.apache.turbine.services.pull 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package org.apache.turbine.services.pull;
002:
003:        /*
004:         * Licensed to the Apache Software Foundation (ASF) under one
005:         * or more contributor license agreements.  See the NOTICE file
006:         * distributed with this work for additional information
007:         * regarding copyright ownership.  The ASF licenses this file
008:         * to you under the Apache License, Version 2.0 (the
009:         * "License"); you may not use this file except in compliance
010:         * with the License.  You may obtain a copy of the License at
011:         *
012:         *   http://www.apache.org/licenses/LICENSE-2.0
013:         *
014:         * Unless required by applicable law or agreed to in writing,
015:         * software distributed under the License is distributed on an
016:         * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
017:         * KIND, either express or implied.  See the License for the
018:         * specific language governing permissions and limitations
019:         * under the License.
020:         */
021:
022:        import org.apache.turbine.services.Service;
023:        import org.apache.turbine.util.RunData;
024:        import org.apache.velocity.context.Context;
025:
026:        /**
027:         * The Pull Service manages the creation of application
028:         * tools that are available to all templates in a
029:         * Turbine application. By using the Pull Service you
030:         * can avoid having to make Screens to populate a
031:         * context for use in a particular template. The Pull
032:         * Service creates a set of tools, as specified in
033:         * the TR.props file.
034:         *
035:         * These tools can have global scope, request scope,
036:         * authorized or session scope (i.e. stored in user temp hashmap)
037:         * or persistent scope (i.e. stored in user perm hashmap)
038:         *
039:         * The standard way of referencing these global
040:         * tools is through the toolbox handle. This handle
041:         * is typically $toolbox, but can be specified in the
042:         * TR.props file.
043:         *
044:         * So, for example, if you had a UI Manager tool
045:         * which created a set of UI attributes from a
046:         * properties file, and one of the properties
047:         * was 'bgcolor', then you could access this
048:         * UI attribute with $ui.bgcolor. The identifier
049:         * that is given to the tool, in this case 'ui', can
050:         * be specified as well.
051:         *
052:         * @author <a href="mailto:jvanzyl@periapt.com">Jason van Zyl</a>
053:         * @author <a href="mailto:hps@intermeta.de">Henning P. Schmiedehausen</a>
054:         * @version $Id: PullService.java 534527 2007-05-02 16:10:59Z tv $
055:         */
056:        public interface PullService extends Service {
057:            /** The key under which this service is stored in TurbineServices. */
058:            String SERVICE_NAME = "PullService";
059:
060:            /** Property Key for the global tools */
061:            String GLOBAL_TOOL = "tool.global";
062:
063:            /** Property Key for the request tools */
064:            String REQUEST_TOOL = "tool.request";
065:
066:            /** Property Key for the session tools */
067:            String SESSION_TOOL = "tool.session";
068:
069:            /** Property Key for the authorized tools */
070:            String AUTHORIZED_TOOL = "tool.authorized";
071:
072:            /** Property Key for the persistent tools */
073:            String PERSISTENT_TOOL = "tool.persistent";
074:
075:            /** Property tag for application tool resources directory */
076:            String TOOL_RESOURCES_DIR_KEY = "tools.resources.dir";
077:
078:            /**
079:             * Default value for the application tool resources. This is relative
080:             * to the webapp root
081:             */
082:            String TOOL_RESOURCES_DIR_DEFAULT = "resources";
083:
084:            /**
085:             * Property tag for per request tool refreshing (for obvious reasons
086:             * has no effect for per-request tools)
087:             */
088:            String TOOLS_PER_REQUEST_REFRESH_KEY = "tools.per.request.refresh";
089:
090:            /** Default value for per request tool refreshing */
091:            boolean TOOLS_PER_REQUEST_REFRESH_DEFAULT = false;
092:
093:            /** prefix for key used in the session to store session scope pull tools */
094:            String SESSION_TOOLS_ATTRIBUTE_PREFIX = "turbine.sessiontools.";
095:
096:            /**
097:             * Get the context containing global tools that will be
098:             * use as part of the Turbine Pull Model.
099:             *
100:             * @return A Context object which contains the
101:             *         Global Tool instances.
102:             */
103:            Context getGlobalContext();
104:
105:            /**
106:             * Populate the given context with all request, session, authorized
107:             * and persistent scope tools (it is assumed that the context
108:             * already wraps the global context, and thus already contains
109:             * the global tools).
110:             *
111:             * @param context a Velocity Context to populate
112:             * @param data a RunData object for request specific data
113:             */
114:            void populateContext(Context context, RunData data);
115:
116:            /**
117:             * Return the absolute path of the resources directory
118:             * used by application tools.
119:             *
120:             * @return A directory path in the file system or null.
121:             */
122:            String getAbsolutePathToResourcesDirectory();
123:
124:            /**
125:             * Return the resources directory. This is relative
126:             * to the webapp context.
127:             *
128:             * @return A directory path to the resources directory relative to the webapp root or null.
129:             */
130:            String getResourcesDirectory();
131:
132:            /**
133:             * Refresh the global tools .
134:             * @deprecated No longer needed as Pull and Velocity Service are now more separate.
135:             */
136:            void refreshGlobalTools();
137:
138:            /**
139:             * Shoud we refresh the tools
140:             * on each request. For development purposes.
141:             *
142:             * @return true if we should refresh the tools on every request.
143:             * @deprecated No longer needed as Pull and Velocity Service are now more separate.
144:             */
145:            boolean refreshToolsPerRequest();
146:
147:            /**
148:             * Release tool instances from the given context to the
149:             * object pool
150:             *
151:             * @param context a Velocity Context to release tools from
152:             */
153:            void releaseTools(Context context);
154:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.