All Packages Class Hierarchy This Package Previous Next Index
Class jumbo.xml.gui.XTable
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----com.sun.java.swing.JComponent
|
+----com.sun.java.swing.JTable
|
+----jumbo.xml.gui.XTable
- public class XTable
- extends JTable
a simple subset of JTable, using defaults. getDisplayComponent()
returns a Component for embedding elsewhere if required and takes
care of JTableHeader (I hope)
-
XTable(String, Object[][], String[])
- make the table from already constructed Object arrays [rows][cols]
and column names [cols]
-
addComboBoxEditor(String, String[])
- add ComboBox editing to a column - see SwingSet example
-
addComponent(String)
- add Component to a cell - see SwingSet example
-
addRow(Object[])
- add a row at end
-
display()
- a default display in a JFrame
-
getCell(int, int)
- get Cell as an object (silly value of iRow, jCol returns null)
-
getDisplayComponent()
- returns a JPanel with a scrolling Table (still experimental)
-
getJFrame()
-
-
getName()
- get the name of the table
-
getRow(int)
- get Row as a Vector of objects (silly value of iRow returns null)
-
getRowCount()
- get information
-
main(String[])
- test routine
-
removeRow(int)
- delete a row
XTable
public XTable(String name,
Object inData[][],
String columnNames[])
- make the table from already constructed Object arrays [rows][cols]
and column names [cols]
- Parameters:
- name - name of the table
- inData - a [row][column] array of Objects
- columnNames - a [column] vector of Strings
- Throws: IllegalArgumentException
- lengths of arrays are inconsistent
addComponent
public void addComponent(String columnName)
- add Component to a cell - see SwingSet example
addComboBoxEditor
public void addComboBoxEditor(String columnName,
String values[])
- add ComboBox editing to a column - see SwingSet example
getName
public String getName()
- get the name of the table
- Returns:
- String name the name of the table
- Overrides:
- getName in class Component
removeRow
public void removeRow(int i)
- delete a row
addRow
public void addRow(Object row[])
- add a row at end
getRowCount
public int getRowCount()
- get information
- Overrides:
- getRowCount in class JTable
getRow
public Vector getRow(int iRow)
- get Row as a Vector of objects (silly value of iRow returns null)
getCell
public Object getCell(int iRow,
int jCol)
- get Cell as an object (silly value of iRow, jCol returns null)
getDisplayComponent
public JPanel getDisplayComponent()
- returns a JPanel with a scrolling Table (still experimental)
- Returns:
- JPanel JPanel containing a JScrollPane
display
public void display()
- a default display in a JFrame
getJFrame
public JFrame getJFrame()
main
public static void main(String args[])
- test routine
All Packages Class Hierarchy This Package Previous Next Index