Browse Prior Art Database

Method for one-time rendering of Web content and state-dependent action processing using the PortletPageListener interface.

IP.com Disclosure Number: IPCOM000030564D
Original Publication Date: 2004-Aug-17
Included in the Prior Art Database: 2004-Aug-17
Document File: 5 page(s) / 59K

Publishing Venue

IBM

Abstract

The PortletPageListener interface of the Portlet API is used to display a Javascript dialog box after a certain action occurs. Portlet rendering is paused until the user responds. This implementation eliminates the need for additional action processing code or a separate portlet view for requesting user input.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 53% of the total text.

Page 1 of 5

Method for one-time rendering of Web content and state -dependent action processing using the PortletPageListener interface .

Disclosed is a method to request user input and suspend the rendering of a portlet until the user response is received.

In normal portlet operation, there are two distinct modes. All events such as button clicks are handled during the action processing phase (the actionPerformed() method). No content can be displayed to the user, until all action processing for all portlets on the page have been completed. Only during the content rendering phase (the doView() method) can Web content such as JavaScript dialog boxes or other HTML be displayed.

This restricts how portlets can implement certain behaviours, such as pausing to get user confirmation, before proceeding with an action, as in the following example:
1. User clicks a logout button in the portlet (HTML form), to disconnect from an application external to the Portal.
2. Portlet starts processing the logout action in actionPerformed() method.
3. Portlet displays a warning dialog box with an OK button.
4. User clicks OK to confirm and proceed with logout.
5. Portlet continues to process action, and logs out.

An alternative program flow which would be permitted is:
1. User clicks a logout button in the portlet (HTML form).
2. Portlet processes the logout action in actionPerformed() method. If the action was recognized, then set a logout flag.
3. After action processing is complete, the portlet will be re-rendered. At the beginning of portlet rendering, check whether the logout flag was set.
4. If set, then show a different HTML form (JSP) that contains a warning message with an OK button.
5. Unset the logout flag at the end of portlet rendering, so that it will not display the warning JSP on the next rendering cycle.
6. When the user clicks OK, process this confirmation action and perform the logout.

However, this requires the developer to add an additional program option, and to maintain an additional JSP file. The server must also handle an additional cycle of action processing and content rendering. This can be a concern since all other portlets on the page must be re-rendered at the same time.

Another possible solution would be to incorporate an applet that requests and receives user input, but that significantly increases the complexity of the portlet.

The disclosed method combines elements of the two flows described above. The action processing phase neither displays a warning dialog box, nor performs the actual logout action. Instead, it only sets a flag in the PortletSession, to...