|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.table.AbstractTableModel
dsto.dfc.swing.table.AbstractDfcTableModel
dsto.dfc.swing.table.ProxyTableModel
public class ProxyTableModel
Generic base class for a table model that act as a proxy for another table model. All calls are by default forwarded to the enclosed table model, events are forwarded out (but with the source changed to the proxy).
| Field Summary | |
|---|---|
protected DfcTableModel |
model
|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Constructor Summary | |
|---|---|
ProxyTableModel(DfcTableModel model)
|
|
| Method Summary | |
|---|---|
boolean |
canCopyCells(int startRow,
int endRow,
int startColumn,
int endColumn)
Test if a copyCells () operation is permitted. |
boolean |
canCopyRows(int startRow,
int endRow)
|
boolean |
canDeleteCells(int startRow,
int endRow,
int startColumn,
int endColumn)
Test if a deleteCells () operation is permitted. |
boolean |
canDeleteColumns(int columnStart,
int columnEnd)
Test if a deleteColumns () operation is supported. |
boolean |
canDeleteRows(int rowStart,
int rowEnd)
Test if a deleteRows () operation is supported. |
boolean |
canInsertColumn(int columnIndex,
String columnName,
Class columnClass)
Test if an insertColumn () operation is supported. |
boolean |
canInsertRows(int rowStart,
int rowEnd)
Test if an insertRows () operation is supported. |
boolean |
canMoveRows(int startRow,
int endRow,
int newStartRow)
|
boolean |
canPasteCells(Transferable transferable,
int startRow,
int endRow,
int startColumn,
int endColumn)
Should return true if rows may be pasted from a given Transferable into a block of cells. |
boolean |
canPasteRows(Transferable transferable,
int rowStart)
Should return true if rows may be pasted from a given Transferable at the given row. |
Transferable |
copyCells(int startRow,
int endRow,
int startColumn,
int endColumn)
Copy a rectangular block of cells into an AWT Transferable. |
Transferable |
copyRows(int startRow,
int endRow)
|
void |
deleteCells(int startRow,
int endRow,
int startColumn,
int endColumn)
Delete a rectangular block of cells. |
void |
deleteColumns(int columnStart,
int columnEnd)
Delete columns. |
void |
deleteRows(int rowStart,
int rowEnd)
Delete rows. |
int |
getColumnCount()
|
String |
getColumnName(int column)
|
int |
getRowCount()
|
DfcTableModel |
getSubModel()
|
Object |
getValueAt(int row,
int col)
|
void |
insertColumn(int columnIndex,
String columnName,
Class columnClass)
Insert a new column containing blank values. |
void |
insertRows(int rowStart,
int rowEnd)
Insert empty rows. |
boolean |
isCellEditable(int rowIndex,
int columnIndex)
|
boolean |
moveRows(int startRow,
int endRow,
int newStartRow)
|
void |
pasteCells(Transferable transferable,
int startRow,
int endRow,
int startColumn,
int endColumn)
|
void |
pasteRows(Transferable transferable,
int rowStart)
|
void |
setValueAt(Object aValue,
int rowIndex,
int columnIndex)
|
void |
tableChanged(TableModelEvent e)
|
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, removeTableModelListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.swing.table.TableModel |
|---|
addTableModelListener, getColumnClass, removeTableModelListener |
| Field Detail |
|---|
protected DfcTableModel model
| Constructor Detail |
|---|
public ProxyTableModel(DfcTableModel model)
| Method Detail |
|---|
public DfcTableModel getSubModel()
public int getColumnCount()
getColumnCount in interface TableModel
public Object getValueAt(int row,
int col)
getValueAt in interface TableModelpublic int getRowCount()
getRowCount in interface TableModelpublic String getColumnName(int column)
getColumnName in interface TableModelgetColumnName in class AbstractTableModel
public boolean canMoveRows(int startRow,
int endRow,
int newStartRow)
canMoveRows in interface DfcTableModelcanMoveRows in class AbstractDfcTableModel
public boolean canPasteRows(Transferable transferable,
int rowStart)
DfcTableModel
canPasteRows in interface DfcTableModelcanPasteRows in class AbstractDfcTableModeltransferable - The transferable.rowStart - The row to insert the transferable at.
public void deleteRows(int rowStart,
int rowEnd)
throws UnsupportedOperationException
DfcTableModel
deleteRows in interface DfcTableModeldeleteRows in class AbstractDfcTableModelrowStart - The row to begin inserting.rowEnd - The last row to delete.
UnsupportedOperationException - if this is not supported.DfcTableModel.canDeleteRows(int, int)
public void deleteColumns(int columnStart,
int columnEnd)
throws UnsupportedOperationException
DfcTableModel
deleteColumns in interface DfcTableModeldeleteColumns in class AbstractDfcTableModelcolumnStart - The index of the first column.columnEnd - The index of the last column.
UnsupportedOperationExceptionDfcTableModel.canDeleteColumns(int, int)
public boolean canCopyRows(int startRow,
int endRow)
canCopyRows in interface DfcTableModelcanCopyRows in class AbstractDfcTableModel
public boolean canInsertRows(int rowStart,
int rowEnd)
DfcTableModel
canInsertRows in interface DfcTableModelcanInsertRows in class AbstractDfcTableModelrowStart - The row to begin inserting.rowEnd - The number of rows to insert.
public boolean isCellEditable(int rowIndex,
int columnIndex)
isCellEditable in interface TableModelisCellEditable in class AbstractTableModel
public boolean canDeleteCells(int startRow,
int endRow,
int startColumn,
int endColumn)
DfcTableModel
canDeleteCells in interface DfcTableModelcanDeleteCells in class AbstractDfcTableModelstartRow - The first row to delete.endRow - The last row to delete.startColumn - The first column to delete.endColumn - The last column to delete.
public void pasteCells(Transferable transferable,
int startRow,
int endRow,
int startColumn,
int endColumn)
throws IOException,
CloneNotSupportedException,
UnsupportedFlavorException,
UnsupportedOperationException
pasteCells in interface DfcTableModelpasteCells in class AbstractDfcTableModelIOException
CloneNotSupportedException
UnsupportedFlavorException
UnsupportedOperationException
public boolean canDeleteRows(int rowStart,
int rowEnd)
DfcTableModel
canDeleteRows in interface DfcTableModelcanDeleteRows in class AbstractDfcTableModelrowStart - The row to begin inserting.rowEnd - The last row to delete.
public Transferable copyRows(int startRow,
int endRow)
throws CloneNotSupportedException,
UnsupportedOperationException
copyRows in interface DfcTableModelcopyRows in class AbstractDfcTableModelCloneNotSupportedException
UnsupportedOperationException
public Transferable copyCells(int startRow,
int endRow,
int startColumn,
int endColumn)
throws CloneNotSupportedException,
UnsupportedOperationException
DfcTableModel
copyCells in interface DfcTableModelcopyCells in class AbstractDfcTableModelstartRow - The first row to copy.endRow - The last row to copy.startColumn - The first column to copy.endColumn - The last column to copy.
CloneNotSupportedException - if a data item could not be cloned.
UnsupportedOperationExceptionDfcTableModel.canCopyRows(int, int)
public boolean canInsertColumn(int columnIndex,
String columnName,
Class columnClass)
DfcTableModel
canInsertColumn in interface DfcTableModelcanInsertColumn in class AbstractDfcTableModelcolumnIndex - The index for the new column.columnName - The name of the new column. May be null to indicate
automatic name.columnClass - The class of values in the column.
public boolean moveRows(int startRow,
int endRow,
int newStartRow)
throws UnsupportedOperationException
moveRows in interface DfcTableModelmoveRows in class AbstractDfcTableModelUnsupportedOperationException
public boolean canDeleteColumns(int columnStart,
int columnEnd)
DfcTableModel
canDeleteColumns in interface DfcTableModelcanDeleteColumns in class AbstractDfcTableModelcolumnStart - The index of the first column.columnEnd - The index of the last column.
public boolean canPasteCells(Transferable transferable,
int startRow,
int endRow,
int startColumn,
int endColumn)
DfcTableModel
canPasteCells in interface DfcTableModelcanPasteCells in class AbstractDfcTableModeltransferable - The transferable.startRow - The row to insert the transferable at.
public void setValueAt(Object aValue,
int rowIndex,
int columnIndex)
setValueAt in interface TableModelsetValueAt in class AbstractTableModel
public void pasteRows(Transferable transferable,
int rowStart)
throws IOException,
CloneNotSupportedException,
UnsupportedFlavorException,
UnsupportedOperationException
pasteRows in interface DfcTableModelpasteRows in class AbstractDfcTableModelIOException
CloneNotSupportedException
UnsupportedFlavorException
UnsupportedOperationException
public boolean canCopyCells(int startRow,
int endRow,
int startColumn,
int endColumn)
DfcTableModel
canCopyCells in interface DfcTableModelcanCopyCells in class AbstractDfcTableModelstartRow - The first row to copy.endRow - The last row to copy.startColumn - The first column to copy.endColumn - The last column to copy.
public void insertRows(int rowStart,
int rowEnd)
DfcTableModel
insertRows in interface DfcTableModelinsertRows in class AbstractDfcTableModelrowStart - The row to begin inserting.rowEnd - The number of rows to insert.DfcTableModel.canInsertRows(int, int)
public void deleteCells(int startRow,
int endRow,
int startColumn,
int endColumn)
throws UnsupportedOperationException
DfcTableModel
deleteCells in interface DfcTableModeldeleteCells in class AbstractDfcTableModelstartRow - The first row to delete.endRow - The last row to delete.startColumn - The first column to delete.endColumn - The last column to delete.
UnsupportedOperationExceptionDfcTableModel.canDeleteCells(int, int, int, int)
public void insertColumn(int columnIndex,
String columnName,
Class columnClass)
throws UnsupportedOperationException
DfcTableModel
insertColumn in interface DfcTableModelinsertColumn in class AbstractDfcTableModelcolumnIndex - The index for the new column.columnName - The name of the new column. May be null to
indicate automatic name.columnClass - The class of values in the column.
UnsupportedOperationExceptionDfcTableModel.canInsertColumn(int, java.lang.String, java.lang.Class)public void tableChanged(TableModelEvent e)
tableChanged in interface TableModelListener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||