|
||||||||||
| 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.DefaultDfcTableModel
public class DefaultDfcTableModel
Fully dynamic implementation of DfcTableModel backed by ArrayList's.
| Field Summary |
|---|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Constructor Summary | |
|---|---|
DefaultDfcTableModel()
|
|
DefaultDfcTableModel(TableModel model,
int startRow,
int endRow,
int startColumn,
int endColumn)
Create a new table model from a rectangular section of an existing table. |
|
| 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 startColumn,
int endColumn)
Test if a deleteColumns () operation is supported. |
boolean |
canDeleteRows(int startRow,
int endRow)
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 startRow,
int rowCount)
Test if an insertRows () operation is supported. |
boolean |
canMoveRows(int startRow,
int endRow,
int newStartRow)
|
boolean |
canPasteRows(Transferable transferable,
int startRow)
Should return true if rows may be pasted from a given Transferable at the given row. |
Object |
clone()
Create a completely separate copy of this object and any mutable objects owned by the object. |
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 startColumn,
int endColumn)
Delete columns. |
void |
deleteRows(int startRow,
int endRow)
Delete rows. |
Class |
getColumnClass(int columnIndex)
|
int |
getColumnCount()
|
String |
getColumnName(int columnIndex)
|
int |
getRowCount()
|
Object |
getValueAt(int rowIndex,
int columnIndex)
|
void |
insertColumn(int columnIndex,
String columnName,
Class columnClass)
Insert a new column containing blank values. |
void |
insertRows(int startRow,
int rowCount)
Insert empty rows. |
boolean |
isCellEditable(int rowIndex,
int columnIndex)
|
boolean |
moveRows(int startRow,
int endRow,
int newStartRow)
|
void |
pasteRows(Transferable transferable,
int startRow)
|
void |
setValueAt(Object value,
int rowIndex,
int columnIndex)
|
| Methods inherited from class dsto.dfc.swing.table.AbstractDfcTableModel |
|---|
canPasteCells, pasteCells |
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface dsto.dfc.swing.table.DfcTableModel |
|---|
canPasteCells, pasteCells |
| Methods inherited from interface javax.swing.table.TableModel |
|---|
addTableModelListener, removeTableModelListener |
| Constructor Detail |
|---|
public DefaultDfcTableModel()
public DefaultDfcTableModel(TableModel model,
int startRow,
int endRow,
int startColumn,
int endColumn)
throws CloneNotSupportedException
CloneNotSupportedException| Method Detail |
|---|
public int getRowCount()
getRowCount in interface TableModelpublic int getColumnCount()
getColumnCount in interface TableModelpublic String getColumnName(int columnIndex)
getColumnName in interface TableModelgetColumnName in class AbstractTableModelpublic Class getColumnClass(int columnIndex)
getColumnClass in interface TableModelgetColumnClass in class AbstractTableModel
public boolean isCellEditable(int rowIndex,
int columnIndex)
isCellEditable in interface TableModelisCellEditable in class AbstractTableModel
public Object getValueAt(int rowIndex,
int columnIndex)
getValueAt in interface TableModel
public void setValueAt(Object value,
int rowIndex,
int columnIndex)
setValueAt in interface TableModelsetValueAt in class AbstractTableModel
public void insertRows(int startRow,
int rowCount)
DfcTableModel
insertRows in interface DfcTableModelinsertRows in class AbstractDfcTableModelstartRow - The row to begin inserting.rowCount - The number of rows to insert.DfcTableModel.canInsertRows(int, int)
public void deleteRows(int startRow,
int endRow)
DfcTableModel
deleteRows in interface DfcTableModeldeleteRows in class AbstractDfcTableModelstartRow - The row to begin inserting.endRow - The last row to delete.DfcTableModel.canDeleteRows(int, int)
public boolean canInsertRows(int startRow,
int rowCount)
DfcTableModel
canInsertRows in interface DfcTableModelcanInsertRows in class AbstractDfcTableModelstartRow - The row to begin inserting.rowCount - The number of rows to insert.
public boolean canDeleteRows(int startRow,
int endRow)
DfcTableModel
canDeleteRows in interface DfcTableModelcanDeleteRows in class AbstractDfcTableModelstartRow - The row to begin inserting.endRow - The last row to delete.
public boolean canMoveRows(int startRow,
int endRow,
int newStartRow)
canMoveRows in interface DfcTableModelcanMoveRows in class AbstractDfcTableModel
public boolean moveRows(int startRow,
int endRow,
int newStartRow)
throws UnsupportedOperationException
moveRows in interface DfcTableModelmoveRows in class AbstractDfcTableModelUnsupportedOperationException
public void insertColumn(int columnIndex,
String columnName,
Class columnClass)
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.DfcTableModel.canInsertColumn(int, java.lang.String, java.lang.Class)
public void deleteColumns(int startColumn,
int endColumn)
DfcTableModel
deleteColumns in interface DfcTableModeldeleteColumns in class AbstractDfcTableModelstartColumn - The index of the first column.endColumn - The index of the last column.DfcTableModel.canDeleteColumns(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 canDeleteColumns(int startColumn,
int endColumn)
DfcTableModel
canDeleteColumns in interface DfcTableModelcanDeleteColumns in class AbstractDfcTableModelstartColumn - The index of the first column.endColumn - The index of the last column.
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 deleteCells(int startRow,
int endRow,
int startColumn,
int endColumn)
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.DfcTableModel.canDeleteCells(int, int, int, int)
public boolean canCopyRows(int startRow,
int endRow)
canCopyRows in interface DfcTableModelcanCopyRows in class AbstractDfcTableModel
public Transferable copyRows(int startRow,
int endRow)
throws UnsupportedOperationException,
CloneNotSupportedException
copyRows in interface DfcTableModelcopyRows in class AbstractDfcTableModelUnsupportedOperationException
CloneNotSupportedException
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 Transferable copyCells(int startRow,
int endRow,
int startColumn,
int endColumn)
throws CloneNotSupportedException
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.DfcTableModel.canCopyRows(int, int)
public boolean canPasteRows(Transferable transferable,
int startRow)
DfcTableModel
canPasteRows in interface DfcTableModelcanPasteRows in class AbstractDfcTableModeltransferable - The transferable.startRow - The row to insert the transferable at.
public void pasteRows(Transferable transferable,
int startRow)
throws UnsupportedOperationException,
UnsupportedFlavorException,
CloneNotSupportedException,
IOException
pasteRows in interface DfcTableModelpasteRows in class AbstractDfcTableModelUnsupportedOperationException
UnsupportedFlavorException
CloneNotSupportedException
IOException
public Object clone()
throws CloneNotSupportedException
CopyableNOTE: subclasses should not remove the CloneNotSupportedException throws clause if they themselves support subclassing: removing the CloneNotSupportedException declaration stops subclasses from indicating that a clone was not possible.
clone in interface Copyableclone in class ObjectCloneNotSupportedException - if the clone failed or is not
possible.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||