How to Use the scrollComponentIntoViewBehavior Tag

5-22 Web User Interface Developers Guide for Oracle Application Development Framework firstname and\n + lastname, we could use a Table with two columns - one for firstname, and the other\n + for lastname - to display a list of Person objects.\n + p\n + div\n + div\n + h2\n + a id=\The_Table_Model\aThe Table Modelh2\n + p\n + . . . div;

5.7 Using Polling Events to Update Pages

ADF Faces provides the poll component whose pollEvent can be used to communicate with the server at specified intervals. For example, you might use the poll component to update an outputText component, or to deliver a heartbeat to the server to prevent a user from being timed out of their session. You need to create a listener for the pollEvent that will be used to do the processing required at poll time. For example, if you want to use the poll component to update the value of an outputText component, you would implement a pollEventListener method that would check the value in the data source and then update the component. You can configure the interval time to determine how often the poll component will deliver its poll event. You also configure the amount of time after which the page will be allowed to time out. This can be useful, as the polling on a page causes the session to never time out. Each time a request is sent to the server, a session time out value is written to the page to determine when to cause a session time out. Because the poll component will continually send a request to the server based on the interval time, the session will never time out. This is expensive both in network usage and in memory. To avoid this issue, the web.xml configuration file contains the oracle.adf.view.rich.poll.TIMEOUT context-parameter, which specifies how long a page should run before it times out. A page is considered eligible to time out if there is no keyboard or mouse activity. The default timeout period is set at ten minutes. So if user is inactive for 10 minutes, that is, does not use the keyboard or mouse, then the framework stops polling, and from that point on, the page participates in the standard server-side session timeout for more information, see Section A.2.3.20, Session Timeout Warning . If the application does time out, when the user moves the mouse or uses the keyboard again, a new session timeout value is written to the page, and polling starts again. You can override this time for a specific page using the poll component’s timeout attribute.

5.7.1 How to Use the Poll Component

When you use the poll component, you normally also create a handler method to handle the functionality for the polling event. Handling Events 5-23 Before You Begin It may be helpful to have an understanding of how the attributes can affect functionality. For more information, see Section 5.7, Using Polling Events to Update Pages To use a poll component: 1. In a managed bean, create a handler for the poll event. For more information about managed beans, see Section 2.6, Creating and Using Managed Beans

2. Create a poll component by dragging and dropping a Poll from the Operations

panel of the Component Palette. 3. In the Property Inspector, expand the Common section and set the following: ■ Interval : Enter the amount of time in milliseconds between poll events. Set to 0 to disable polling. ■ PollListener : Enter an EL expression that evaluates to the method in Step 1. 4. If you want to override the global timeout value in the web.xml file, expand the Other section and set Timeout to the amount of time in milliseconds after which the page will stop polling and the session will time out. 5-24 Web User Interface Developers Guide for Oracle Application Development Framework