HTML Client 5.0.1

Class ScreenTableHelper


class ScreenTableHelper

Helper class that can be used in order to help the framework finding the HTML cells that make up a screen table in the page DOM. It can be used to explicitly declare the cells to be used avoiding any DOM search or to specify a root node to limit the scanning of the page and/or to specify a subset of node types to be searched for Lightsreamer attributes.
When a data table is brought to "running" state through PushPage.addTable(), the screen table to be used to display its values is also determined, based on the supplied id. This requires a search throughout the page DOM for all the HTML nodes that declare the specified id as their screen table id. This search operation may be inefficient. Such load can be eased using a ScreenTableHelper properly configured and notified through PushPage.addScreenTableHelper():

Hence, using helper objects is recommended when a huge number of PushPage.addTable() calls is performed and populating the helper objects can be made in an efficient way.
Dynamically changing screen tables are supported. When new HTML cells are created for a screen table, their pointers can be added through the addCell() method. HTML cells that are removed from the page, on the other hand, don't need to be notified. It is also possible to change the root node or the node types for future searches. However previously found cells will be kept as part of the screen table unless detached from the page. Note that all the changes to an existing screen table are only performed during an PushPage.addTable() execution.
The ScreenTableHelper helper can only be used with basic screen tables, that is, screen tables suitable for association to OverwriteTable, ScrollTable or MetapushTable data tables.
Defined in lspushpage.js

Constructor Summary
ScreenTableHelper (<String> id, <Array> tableCells)
            Creates a helper object that can be used in order to help the framework finding the HTML cells that make up a screen table in the page DOM.
Method Summary
 void addCell(<DOMElement> cellElement)
           Operation method that adds an HTML cell pointer to a screen table helper.
 void setNodeTypes(<Array> nodeTypes)
           Setter method that specifies a list of HTML element types to be searched for during the population of the screen table associated with this ScreenTableHelper.
 void setRootNode(<DOMElement> rootNode)
           Setter method that specifies the root node to be used when searching for screen table cells.

Constructor Detail


ScreenTableHelper(<String> id, <Array> tableCells)

Method Detail


void addCell(<DOMElement> cellElement)


void setNodeTypes(<Array> nodeTypes)


void setRootNode(<DOMElement> rootNode)

HTML Client 5.0.1

Lightstreamer HTML Client API
Documentation generated by JSDoc on Tue May 22 11:46:54 2012