Java Doc for ElementTableBase.java in  » Ajax » ItsNat » org » itsnat » core » domutil » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Ajax » ItsNat » org.itsnat.core.domutil 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.itsnat.core.domutil.ElementTableBase

All known Subclasses:   org.itsnat.impl.core.domutil.ElementTableBaseImpl,
ElementTableBase
public interface ElementTableBase extends ElementListBase(Code)
This utility interface represents and manages an integer indexed DOM Element table, a row list of consecutive elements with a single parent element, every row element contains again an element list (cells).

Objects implementing this interface are attached to a real DOM element table with a single parent element, this "initial" table may be not empty, in fact it is automatically synchronized with the "real" DOM element table to show the current state when the utility object is created.

This interface only manages DOM Element objects as row and cell elements, other node types like text nodes are ignored (filtered).

Indexes are zero-based.

When a DOM element (a new row or a new cell/column) is added or removed using this interface, this element is added/removed to/from the DOM table too.

This interface inherits from ElementListBase , the list interface see the table as a list of rows.


author:
   Jose Maria Arranz Santamaria




Method Summary
public  ElementgetCellElementAt(int row, int column)
     Returns the cell element at the specified row and column.
Parameters:
  row - the row index of the cell element to search.
Parameters:
  column - the column index of the cell element to search.
public  Element[]getCellElementsOfColumn(int column)
     Returns the cell elements of the specified column as an array.
Parameters:
  column - the column index.
public  Element[]getCellElementsOfRow(int row)
     Returns the cell elements of the specified row as an array.
Parameters:
  row - the row index.
public  Element[]getElementRows()
     Returns the row element list as an array.
public  ElementgetFirstRowElement()
     Returns the first row element (row at position 0).
public  ElementgetLastRowElement()
     Returns the last row element (row at position length - 1).
public  intgetRowCount()
     Returns the number of rows.
public  ElementgetRowElementAt(int row)
     Returns the row element at the specified index.
Parameters:
  row - index of the row to search.
public  ElementgetRowElementFromNode(Node node)
     Returns the row element of the table containing the specified node.
public  ListElementInfogetRowListElementInfoAt(int index)
     Returns an object info of the row element at the specified position.
Parameters:
  index - index of the row.
public  ListElementInfogetRowListElementInfoFromNode(Node node)
     Returns an object info of the row element containing the specified node (or the node is itself a row element).
Parameters:
  node - the node to search for.
public  TableCellElementInfogetTableCellElementInfoAt(int row, int column)
     Returns an object info of the cell element specified by the row and column indexes.
Parameters:
  row - row index of the cell element.
Parameters:
  column - column index of the cell element.
public  TableCellElementInfogetTableCellElementInfoFromNode(Node node)
     Returns an object info of the cell element containing the specified node (or the node is itself a cell element of the table).
Parameters:
  node - the node to search for.
public  intindexOfRowElement(Element elem)
     Returns the position of the specified row element.
Parameters:
  elem - the element to search.
public  intlastIndexOfRowElement(Element elem)
     Returns the position of the specified row element searching backwards.

The result must be the same as ElementTableBase.indexOfRowElement(Element) because there is no "duplicated" elements.

public  voidmoveColumn(int columnIndex, int newIndex)
     Moves the column at columnIndex to newIndex.
public  voidmoveRow(int start, int end, int to)
     Moves one or more row elements from the inclusive range start to end to the to position in the table.
public  voidremoveAllColumns()
     Removes all columns.
public  voidremoveAllRows()
     Removes all row elements.
public  voidremoveColumnAt(int column)
     Removes the specified column.
Parameters:
  column - index of the column to remove.
public  ElementremoveRowAt(int row)
     Removes the specified row element.
Parameters:
  row - index of the row element to remove.
public  voidremoveRowRange(int fromIndex, int toIndex)
     Removes the row elements between the specified indexes.



Method Detail
getCellElementAt
public Element getCellElementAt(int row, int column)(Code)
Returns the cell element at the specified row and column.
Parameters:
  row - the row index of the cell element to search.
Parameters:
  column - the column index of the cell element to search. the element in this position or null if some index is out of range.



getCellElementsOfColumn
public Element[] getCellElementsOfColumn(int column)(Code)
Returns the cell elements of the specified column as an array.
Parameters:
  column - the column index. the cell element array or null if index is out of range..



getCellElementsOfRow
public Element[] getCellElementsOfRow(int row)(Code)
Returns the cell elements of the specified row as an array.
Parameters:
  row - the row index. the cell element array or null if index is out of range.



getElementRows
public Element[] getElementRows()(Code)
Returns the row element list as an array. the element array.



getFirstRowElement
public Element getFirstRowElement()(Code)
Returns the first row element (row at position 0). the first row element or null is the table is empty.



getLastRowElement
public Element getLastRowElement()(Code)
Returns the last row element (row at position length - 1). the last row element or null is the table is empty.



getRowCount
public int getRowCount()(Code)
Returns the number of rows. the number of rows.



getRowElementAt
public Element getRowElementAt(int row)(Code)
Returns the row element at the specified index.
Parameters:
  row - index of the row to search. the row element in this position or null if index is out of range.



getRowElementFromNode
public Element getRowElementFromNode(Node node)(Code)
Returns the row element of the table containing the specified node. If the node is itself a row element, self is returned.
Parameters:
  node - the node to search for. the row element containing or equal the specified node. Null if this node is not contained by the table.
See Also:   ElementTableBase.indexOfRowElement(Element)
See Also:   ElementTableBase.getRowListElementInfoFromNode(Node)



getRowListElementInfoAt
public ListElementInfo getRowListElementInfoAt(int index)(Code)
Returns an object info of the row element at the specified position.
Parameters:
  index - index of the row. the object info of the specified row element. Null if index is out of range.
See Also:   ElementTableBase.getRowListElementInfoFromNode(Node)



getRowListElementInfoFromNode
public ListElementInfo getRowListElementInfoFromNode(Node node)(Code)
Returns an object info of the row element containing the specified node (or the node is itself a row element).
Parameters:
  node - the node to search for. the object info of the matched row element. Null if this node is not contained by the table.
See Also:   ElementTableBase.getRowElementFromNode(Node)



getTableCellElementInfoAt
public TableCellElementInfo getTableCellElementInfoAt(int row, int column)(Code)
Returns an object info of the cell element specified by the row and column indexes.
Parameters:
  row - row index of the cell element.
Parameters:
  column - column index of the cell element. the object info of the matched cell element. Null if some index is out of range.
See Also:   ElementTableBase.getTableCellElementInfoFromNode(Node)



getTableCellElementInfoFromNode
public TableCellElementInfo getTableCellElementInfoFromNode(Node node)(Code)
Returns an object info of the cell element containing the specified node (or the node is itself a cell element of the table).
Parameters:
  node - the node to search for. the object info of the matched cell element. Null if this node is not contained by the table.
See Also:   ElementTableBase.getTableCellElementInfoAt(int,int)



indexOfRowElement
public int indexOfRowElement(Element elem)(Code)
Returns the position of the specified row element.
Parameters:
  elem - the element to search. the position or -1 if the specified element is not in the row list.



lastIndexOfRowElement
public int lastIndexOfRowElement(Element elem)(Code)
Returns the position of the specified row element searching backwards.

The result must be the same as ElementTableBase.indexOfRowElement(Element) because there is no "duplicated" elements. Use this method if the specified element is near to the end of the list.


Parameters:
  elem - the element to search. the element position or -1 if the specified element is not in the row list.



moveColumn
public void moveColumn(int columnIndex, int newIndex)(Code)
Moves the column at columnIndex to newIndex. The old column at columnIndex will now be found at newIndex. The column that used to be at newIndex is shifted left or right to make room. This will not move any columns if columnIndex equals newIndex.
Parameters:
  columnIndex - the index of the column to be moved
Parameters:
  newIndex - new index to move the column



moveRow
public void moveRow(int start, int end, int to)(Code)
Moves one or more row elements from the inclusive range start to end to the to position in the table. After the move, the row element that was at index start will be at index to.

The algorithm is explained in ElementListBase.moveElement(intintint) .


Parameters:
  start - the starting element index to be moved
Parameters:
  end - the ending element index to be moved
Parameters:
  to - the destination of the elements to be moved



removeAllColumns
public void removeAllColumns()(Code)
Removes all columns. The table remains as a row list with no cells.



removeAllRows
public void removeAllRows()(Code)
Removes all row elements. The table is now empty.



removeColumnAt
public void removeColumnAt(int column)(Code)
Removes the specified column.
Parameters:
  column - index of the column to remove.



removeRowAt
public Element removeRowAt(int row)(Code)
Removes the specified row element.
Parameters:
  row - index of the row element to remove. the removed element or null if index is out of bounds.



removeRowRange
public void removeRowRange(int fromIndex, int toIndex)(Code)
Removes the row elements between the specified indexes.
Parameters:
  fromIndex - low index (inclusive).
Parameters:
  toIndex - high index (inclusive).



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.