The term portlet refers to a small reusable program that can be placed on the portal page to perform a specific function, such as retrieve and display a piece of information.
Similar to servlets, Portlets are web components that are deployed inside of a container and generate dynamic content. On the technical side, a portlet is a class that implements the javax.portlet.Portlet interface and is packaged and deployed as a .war file inside of a portlet container.
Portlets are similar to servlets, in that:
- Portlets are managed by a specialized container.
- Portlets generate dynamic content.
- A portlet's life cycle is managed by the container.
- Portlets interact with web client via a request/response paradigm.
Portlets are different from servlets, in that:
- Portlets only generate markup fragments, not complete documents.
- Portlets are not directly URL addressable. You cant send somebody URL of a portlet. You can send him the URL of the page containing a portlet.
- Portlets cannot generate arbitrary content, since the content generated by a portlet is going to be part of portal page. If a portal server is asking for html/text, then all portlets should generate text/html content. On the other hand, if the portal server is asking for WML, then each portlet should generate WML content.
No comments:
Post a Comment