|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--net.sf.jeppers.grid.AbstractGridModel
|
+--net.sf.jeppers.grid.DefaultGridModel
This is an implementation of GridModel that uses
a Map of cell points to the cell object values.
| Field Summary |
| Fields inherited from class net.sf.jeppers.grid.AbstractGridModel |
listenerList |
| Constructor Summary | |
DefaultGridModel(int rows,
int columns)
|
|
| Method Summary | |
int |
getColumnCount()
Return the number of columns in the model. |
int |
getRowCount()
Returns the number of rows in the model. |
Object |
getValueAt(int row,
int column)
Returns the value for the cell at row and column |
void |
insertColumns(int column,
int columnCount)
Insert columnCount columns at column. |
void |
insertRows(int row,
int rowCount)
Insert rowCount rows at row. |
boolean |
isCellEditable(int row,
int column)
Returns true if the cell at row and column
is editable. |
void |
removeColumns(int column,
int columnCount)
Remove columnCount columns at column. |
void |
removeRows(int row,
int rowCount)
Remove rowCount rows at row. |
void |
setCellLock(boolean lock,
int row,
int column)
Set whether cell at row and column
can be editted. |
void |
setValueAt(Object value,
int row,
int column)
Sets the value for the cell at row and column
to value |
| Methods inherited from class net.sf.jeppers.grid.AbstractGridModel |
addGridModelListener, fireGridCellUpdated, fireGridChanged, fireGridColumnsDeleted, fireGridColumnsInserted, fireGridColumnsUpdated, fireGridModelChanged, fireGridRowsDeleted, fireGridRowsInserted, fireGridRowsUpdated, getListeners, removeGridModelListener |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DefaultGridModel(int rows,
int columns)
| Method Detail |
public int getRowCount()
GridModel
getRowCount in interface GridModelpublic int getColumnCount()
GridModel
getColumnCount in interface GridModel
public Object getValueAt(int row,
int column)
GridModelrow and column
getValueAt in interface GridModelrow - row index of cellcolumn - column index of cell
public boolean isCellEditable(int row,
int column)
GridModelrow and column
is editable. Otherwise, setValueAt on the cell will not change
the value of that cell.
isCellEditable in interface GridModelrow - row index of cellcolumn - column index of cell
public void setCellLock(boolean lock,
int row,
int column)
row and column
can be editted.
lock - lock flag of cellrow - row index of cellcolumn - column index of cell
public void setValueAt(Object value,
int row,
int column)
GridModelrow and column
to value
setValueAt in interface GridModelvalue - new cell valuerow - row index of cellcolumn - column index of cell
public void insertRows(int row,
int rowCount)
ResizableGridrowCount rows at row.
insertRows in interface ResizableGridrow - the row to insert atrowCount - the number of rows to insert
public void removeRows(int row,
int rowCount)
ResizableGridrowCount rows at row.
removeRows in interface ResizableGridrow - the row to remove fromrowCount - the number of rows to remove
public void insertColumns(int column,
int columnCount)
ResizableGridcolumnCount columns at column.
insertColumns in interface ResizableGridcolumn - the column to insert atcolumnCount - the number of columns to insert
public void removeColumns(int column,
int columnCount)
ResizableGridcolumnCount columns at column.
removeColumns in interface ResizableGridcolumn - the column to remove fromcolumnCount - the number of columns to remove
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||