Java Doc for __Portlet__.java in  » Portal » Open-Portal » __PACKAGE__ » 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 » Portal » Open Portal » __PACKAGE__ 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   __PACKAGE__.__NAME__

__NAME__
public class __NAME__ implements Portlet(Code)
The Portlet interface is used by the portlet container to invoke the portlets. Every portlet has to implement this interface, either by directly implementing it, or by using an existing class implementing the Portlet interface.

A portlet is a Java technology based web component, managed by a portlet container, that processes requests and generates dynamic content. Portlets are used by portals as pluggable user interface components that provide a presentation layer to Information Systems.

The content generated by a portlet is called a fragment. A fragment is a piece of markup (e.g. HTML, XHTML, WML) adhering to certain rules and can be aggregated with other fragments to form a complete document. The content of a portlet is normally aggregated with the content of other portlets to form the portal page. The lifecycle of a portlet is managed by the portlet container.

The portlet container instanciates portlets, manages their lifecycle and invoking them to process requests. The lifecycle consists of:

  • initializing the portlet using using the init method
  • request processsing
  • taking the portlet out of service using the destroy method

Request processing is divided into two types:

  • action requests handled through the processAction method, to perform actions targeted to the portlet
  • render requests handled through the render method, to perform the render operation



Constructor Summary
public  __NAME__()
    

Method Summary
public  voiddestroy()
     Called by the portlet container to indicate to a portlet that the portlet is being taken out of service.
public  voidinit(PortletConfig config)
     Calle_d by the portlet container to indicate to a portlet that the portlet is being placed into service.
public  voidprocessAction(ActionRequest request, ActionResponse actionResponse)
     Notifies this portlet that a client request is triggered by an action URL to this portlet.
public  voidrender(RenderRequest request, RenderResponse response)
     Notifies this portlet to generate its markup using the given request/response pair.


Constructor Detail
__NAME__
public __NAME__()(Code)




Method Detail
destroy
public void destroy()(Code)
Called by the portlet container to indicate to a portlet that the portlet is being taken out of service.

Before the portlet container calls the destroy method, it should allow any threads that are currently processing requests within the portlet object to complete execution. To avoid waiting forever, the portlet container can optionally wait for a predefined time before destroying the portlet object.

This method enables the portlet to do the following:

  • clean up any resources that it holds (for example, memory, file handles, threads)
  • make sure that any persistent state is synchronized with the portlet current state in memory.



init
public void init(PortletConfig config) throws PortletException(Code)
Calle_d by the portlet container to indicate to a portlet that the portlet is being placed into service.

The portlet container calls the init method exactly once after instantiating the portlet. The init method must complete successfully before the portlet can receive any requests.

The portlet container cannot place the portlet into service if the init method

  1. Throws a PortletException
  2. Does not return within a time period defined by the portlet container.

Parameters:
  config - a PortletConfig object containing the portlet'sconfiguration and initialization parameters
exception:
  PortletException - if an exception has occurred thatinterferes with the portlet's normaloperation.
exception:
  UnavailableException - if the portlet is unavailable to perform init



processAction
public void processAction(ActionRequest request, ActionResponse actionResponse) throws PortletException, java.io.IOException(Code)
Notifies this portlet that a client request is triggered by an action URL to this portlet.

Typically, in response to an action request, a portlet updates state based on the information sent in the action request parameters. In an action the portlet may:

    issue a redirect change its window state change its portlet mode change its persistent state set render parameters

This method is only called if the portlet has created an action URL with RenderResponse.createActionURL().

A client request triggered by an action URL translates into one action request and many render requests, one per portlet in the portal page. The action processing must be finished before the render requests can be issued.
Parameters:
  request - the portlet request
Parameters:
  actionResponse - the action response
exception:
  PortletException - if the portlet has problems fulfilling therequest
exception:
  UnavailableException - if the portlet is unavailable to perform processAction
exception:
  PortletSecurityException - if the portlet cannot fullfill this request because of security reasons
exception:
  IOException - if the streaming causes an I/O problem




render
public void render(RenderRequest request, RenderResponse response) throws PortletException, java.io.IOException(Code)
Notifies this portlet to generate its markup using the given request/response pair. Depending on the the current state and the requesting client device, the markup might differ.

The state of a portlet may include, but is not restricted to:

    the window state the portlet portlet mode render parameter request attributes preference data session data

Parameters:
  request - the portlet request
Parameters:
  response - the render response
exception:
  PortletException - if the portlet has problems fulfilling therendering request
exception:
  UnavailableException - if the portlet is unavailable to perform render
exception:
  PortletSecurityException - if the portlet cannot fullfill this request because of security reasons
exception:
  IOException - if the streaming causes an I/O problem



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(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.