org.itsnat.core.domutil
Interface ElementTableStructure


public interface ElementTableStructure

Used by ElementTable objects to obtain row and cell content elements.

Author:
Jose Maria Arranz Santamaria
See Also:
ElementTable.setElementTableStructure(ElementTableStructure), ElementGroupManager.createDefaultElementTableStructure()

Method Summary
 org.w3c.dom.Element getCellContentElement(ElementTable table, int row, int col, org.w3c.dom.Element cellElem)
          Returns the content element of a cell.
 org.w3c.dom.Element getRowContentElement(ElementTable table, int row, org.w3c.dom.Element rowElem)
          Returns the content element of a row.
 

Method Detail

getRowContentElement

org.w3c.dom.Element getRowContentElement(ElementTable table,
                                         int row,
                                         org.w3c.dom.Element rowElem)
Returns the content element of a row.

A row content element is the direct parent element of the row cells. This element is used to access the row cells.

Parameters:
table - the target table, may be used to provide contextual information. Default implementation ignores it.
row - index of the row.
rowElem - the element containing the row (row element). This element is a hint, if provided, should be the same as returned by table.getRowElementAt(index).
Returns:
the row content element. Default implementation returns rowElem.
See Also:
ElementTableRenderer.renderTable(ElementTable,int,int,Object,Element,boolean)

getCellContentElement

org.w3c.dom.Element getCellContentElement(ElementTable table,
                                          int row,
                                          int col,
                                          org.w3c.dom.Element cellElem)
Returns the content element of a cell.

The cell content element is the parent element containing the markup of the associated value usually a text node. This element is passed to the renderer method ElementTableRenderer.renderTable(ElementTable,int,int,Object,Element,boolean).

Parameters:
table - the target table, may be used to provide contextual information. Default implementation ignores it.
row - index of the row.
col - index of the column.
cellElem - the element containing the cell (cell element). This element is a hint, if provided, should be the same as returned by table.getCellElementAt(row,col).
Returns:
the cell content element. Default implementation returns cellElem.


Copyright © 2007 Innowhere Software Services S.L. All Rights Reserved.