|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.deegree_impl.model.table.Table_Impl
-----------------------------------------------------------------------
| Field Summary | |
private java.lang.String[] |
columnNames
|
private java.util.HashMap |
columnNamesMap
|
private java.lang.String[] |
columnTypes
|
private java.util.ArrayList |
rows
|
private java.lang.String |
tableName
|
| Constructor Summary | |
Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes)
|
|
Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes,
int initialCapacity)
|
|
Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes,
java.lang.Object[][] data)
|
|
| Method Summary | |
void |
addColumn(java.lang.String name,
java.lang.String type)
adds a new column to the table. for this a computional expensive operation this method should be used with care. |
void |
appendRow(java.lang.Object[] data)
appends a row to the table and sets its data |
javax.swing.table.TableModel |
exportAsJDKTableModel()
export the table as a instance of javax.swing.table.TableModel. |
int |
getColumnCount()
returns the number columns of the table |
int |
getColumnIndex(java.lang.String columnName)
returns the index of the submitted columns name. |
java.lang.String |
getColumnName(int col)
returns the name of the specified column. |
java.lang.String[] |
getColumnNames()
returns the names of all table columns. |
java.lang.String |
getColumnType(int col)
returns the name of the type of the specifies column. |
java.lang.String[] |
getColumnTypes()
returns the names of all column types. |
java.lang.Object[] |
getRow(int row)
returns the data of the row'th row of the table |
int |
getRowCount()
returns the number rows of the table |
java.lang.String |
getTableName()
returns the name of the table. |
java.lang.Object |
getValueAt(int row,
int col)
returns the value of the table field indexed by row and col |
java.lang.Object[] |
removeRow(int index)
removes a row from the table |
void |
setColumnName(int col,
java.lang.String name)
sets the name of a column. |
void |
setColumnType(int col,
java.lang.String type)
sets the type of a column. |
void |
setRow(java.lang.Object[] data,
int row)
sets the data of the row'th row |
void |
setTableName(java.lang.String tableName)
|
void |
setValueAt(java.lang.Object value,
int row,
int col)
set a value at the table field indexed by row and col |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
private java.lang.String tableName
private java.util.ArrayList rows
private java.lang.String[] columnNames
private java.lang.String[] columnTypes
private java.util.HashMap columnNamesMap
| Constructor Detail |
public Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes)
throws TableException
tableName - columnNames - columnTypes -
TableException
public Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes,
java.lang.Object[][] data)
throws TableException
tableName - columnNames - columnTypes - data -
TableException
public Table_Impl(java.lang.String tableName,
java.lang.String[] columnNames,
java.lang.String[] columnTypes,
int initialCapacity)
throws TableException
tableName - columnNames - columnTypes - initialCapacity -
TableException| Method Detail |
public java.lang.String getTableName()
getTableName in interface Tablepublic void setTableName(java.lang.String tableName)
setTableName in interface TablegetTableName()
public java.lang.Object getValueAt(int row,
int col)
getValueAt in interface Table
public void setValueAt(java.lang.Object value,
int row,
int col)
setValueAt in interface Tablepublic java.lang.Object[] getRow(int row)
getRow in interface Table
public void setRow(java.lang.Object[] data,
int row)
throws TableException
setRow in interface TableTableException
public void appendRow(java.lang.Object[] data)
throws TableException
appendRow in interface TableTableExceptionpublic int getRowCount()
getRowCount in interface Table
public void addColumn(java.lang.String name,
java.lang.String type)
addColumn in interface Tablepublic int getColumnCount()
getColumnCount in interface Tablepublic java.lang.String[] getColumnNames()
getColumnNames in interface Tablepublic java.lang.String getColumnName(int col)
getColumnName in interface Tablepublic java.lang.String[] getColumnTypes()
getColumnTypes in interface Tablepublic java.lang.String getColumnType(int col)
getColumnType in interface Table
public void setColumnType(int col,
java.lang.String type)
throws TableException
setColumnType in interface TableTableException
public void setColumnName(int col,
java.lang.String name)
setColumnName in interface Tablepublic java.lang.Object[] removeRow(int index)
removeRow in interface Tablepublic javax.swing.table.TableModel exportAsJDKTableModel()
public int getColumnIndex(java.lang.String columnName)
getColumnIndex in interface Tablepublic java.lang.String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||