Java Doc for PortletContentGenerator.java in  » J2EE » spring-framework-2.0.6 » org » springframework » web » portlet » handler » 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 » J2EE » spring framework 2.0.6 » org.springframework.web.portlet.handler 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.springframework.web.portlet.context.PortletApplicationObjectSupport
   org.springframework.web.portlet.handler.PortletContentGenerator

All known Subclasses:   org.springframework.web.portlet.mvc.AbstractController,
PortletContentGenerator
abstract public class PortletContentGenerator extends PortletApplicationObjectSupport (Code)
Convenient superclass for any kind of web content generator, like AbstractController. Can also be used for custom handlers that have their own HandlerAdapter.

Supports portlet cache control options.
author:
   Juergen Hoeller
author:
   John A. Lewis
since:
   2.0
See Also:   org.springframework.web.portlet.mvc.AbstractController





Method Summary
final protected  voidapplyCacheSeconds(RenderResponse response, int seconds)
    
final protected  voidcacheForSeconds(RenderResponse response, int seconds)
     Set portlet response to allow caching for the given number of seconds.
final protected  voidcheck(PortletRequest request, PortletResponse response)
     Check and prepare the given request and response according to the settings of this generator.
final protected  voidcheckAndPrepare(RenderRequest request, RenderResponse response)
     Check and prepare the given request and response according to the settings of this generator.
final protected  voidcheckAndPrepare(RenderRequest request, RenderResponse response, int cacheSeconds)
     Check and prepare the given request and response according to the settings of this generator.
final public  intgetCacheSeconds()
     Return the number of seconds that content is cached.
final public  booleanisRequireSession()
     Return whether a session is required to handle requests.
final protected  voidpreventCaching(RenderResponse response)
     Prevent the render response from being cached.
final public  voidsetCacheSeconds(int seconds)
     Cache content for the given number of seconds.
final public  voidsetRequireSession(boolean requireSession)
     Set whether a session should be required to handle requests.



Method Detail
applyCacheSeconds
final protected void applyCacheSeconds(RenderResponse response, int seconds)(Code)
Apply the given cache seconds to the render response
Parameters:
  response - current portlet render response
Parameters:
  seconds - positive number of seconds into the future that theresponse should be cacheable for, 0 to prevent caching



cacheForSeconds
final protected void cacheForSeconds(RenderResponse response, int seconds)(Code)
Set portlet response to allow caching for the given number of seconds.
Parameters:
  response - current portlet render response
Parameters:
  seconds - number of seconds into the future that the responseshould be cacheable for



check
final protected void check(PortletRequest request, PortletResponse response) throws PortletException(Code)
Check and prepare the given request and response according to the settings of this generator. Checks for a required session, and applies the number of cache seconds configured for this generator (if it is a render request/response).
Parameters:
  request - current portlet request
Parameters:
  response - current portlet response
throws:
  PortletException - if the request cannot be handled because a check failed



checkAndPrepare
final protected void checkAndPrepare(RenderRequest request, RenderResponse response) throws PortletException(Code)
Check and prepare the given request and response according to the settings of this generator. Checks for a required session, and applies the number of cache seconds configured for this generator (if it is a render request/response).
Parameters:
  request - current portlet request
Parameters:
  response - current portlet response
throws:
  PortletException - if the request cannot be handled because a check failed



checkAndPrepare
final protected void checkAndPrepare(RenderRequest request, RenderResponse response, int cacheSeconds) throws PortletException(Code)
Check and prepare the given request and response according to the settings of this generator. Checks for a required session, and applies the given number of cache seconds (if it is a render request/response).
Parameters:
  request - current portlet request
Parameters:
  response - current portlet response
Parameters:
  cacheSeconds - positive number of seconds into the future that theresponse should be cacheable for, 0 to prevent caching
throws:
  PortletException - if the request cannot be handled because a check failed



getCacheSeconds
final public int getCacheSeconds()(Code)
Return the number of seconds that content is cached.



isRequireSession
final public boolean isRequireSession()(Code)
Return whether a session is required to handle requests.



preventCaching
final protected void preventCaching(RenderResponse response)(Code)
Prevent the render response from being cached.



setCacheSeconds
final public void setCacheSeconds(int seconds)(Code)
Cache content for the given number of seconds. Default is -1, indicating no override of portlet content caching.

Only if this is set to 0 (no cache) or a positive value (cache for this many seconds) will this class override the portlet settings.

The cache setting can be overwritten by subclasses, before content is generated.




setRequireSession
final public void setRequireSession(boolean requireSession)(Code)
Set whether a session should be required to handle requests.



Methods inherited from org.springframework.web.portlet.context.PortletApplicationObjectSupport
final protected PortletContext getPortletContext() throws IllegalStateException(Code)(Java Doc)
final protected File getTempDir() throws IllegalStateException(Code)(Java Doc)
protected boolean isContextRequired()(Code)(Java Doc)
public void setPortletContext(PortletContext portletContext)(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.