|
JIDE 3.5.15 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.swing.table.AbstractTableModel
com.jidesoft.grid.AbstractPageTableModel
public abstract class AbstractPageTableModel
AbstractPageTableModel is the abstract implementation for PagingSupport. It extends
AbstractTableModel and implements all methods PageNavigationSupport except
PageNavigationSupport.getTotalRecordCount() and PageNavigationSupport.setTotalRecordCount(int).
| Field Summary |
|---|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Fields inherited from interface com.jidesoft.grid.MultiTableModel |
|---|
FOOTER_COLUMN, HEADER_COLUMN, REGULAR_COLUMN |
| Constructor Summary | |
|---|---|
AbstractPageTableModel()
|
|
AbstractPageTableModel(int pageSize)
|
|
| Method Summary | |
|---|---|
void |
addPageNavigationListener(PageNavigationListener l)
Adds a PageNavigationListener to the page. |
protected CompoundTableModelEvent |
createCompoundTableModelEvent()
Creates a CompoundTableModelEvent instance. |
void |
firePageNavigationEvent(Object source,
int id,
int oldValue,
int newValue)
Runs each PageNavigationListener's PageNavigationEventFired method. |
void |
fireTableCellsUpdated(int firstRow,
int lastRow,
int column)
Called each time the cells in column in the range [firstRow, lastRow] are
updated. |
void |
fireTableChanged(TableModelEvent e)
|
void |
firstPage()
Navigates to the first page. |
Class<?> |
getCellClassAt(int rowIndex,
int columnIndex)
Gets the type at cell (row, column). |
int |
getColumnType(int columnIndex)
Checks if the column at the columnIndex is a header column or footer column or just regular column. |
ConverterContext |
getConverterContextAt(int rowIndex,
int columnIndex)
Gets the converter context at cell (row, column). |
int |
getCurrentPage()
Gets the current page. |
EditorContext |
getEditorContextAt(int rowIndex,
int columnIndex)
Gets the editor context at cell (row, column). |
int |
getPageCount()
Gets the total page count. |
PageNavigationListener[] |
getPageNavigationListeners()
Returns an array of all the PageNavigationListeners added to this Page with
addPageNavigationListener . |
int |
getPageSize()
Gets the page size. |
int |
getRowCount()
|
int |
getTableIndex(int columnIndex)
Gets the table index that this column belongs to. |
void |
lastPage()
Navigates to the last page. |
void |
nextPage()
Navigates to the next page. |
protected abstract void |
pageCountChanged(int oldPageCount,
int newPageCount)
|
protected abstract void |
pageIndexChanged(int oldPageIndex,
int newPageIndex)
|
protected void |
pageSizeChanged(int oldPageSize,
int newPageSize)
Adjusts the current page when page size changes so that the first row of the page is still visible after the page size changes. |
void |
previousPage()
Navigates to the previous page. |
void |
removePageNavigationListener(PageNavigationListener l)
Removes a PageNavigationListener from the page. |
void |
setCurrentPage(int page)
Sets the current page. |
protected void |
setPageCount(int pageCount)
|
void |
setPageSize(int pageSize)
Sets the page size. |
protected void |
tableCellsUpdated(int column,
int firstRow,
int lastRow)
Called each time the cells in column in the range [firstRow, lastRow] are
updated. |
void |
tableChanged(TableModelEvent e)
|
protected void |
tableDataChanged()
Called each time all of the data (i.e. |
protected void |
tableRowsDeleted(int firstRow,
int lastRow)
Called each time one or more contiguous rows are deleted from the underlying TableModel. |
protected void |
tableRowsInserted(int firstRow,
int lastRow)
Called each time one or more contiguous rows are inserted into the underlying TableModel. |
protected void |
tableRowsUpdated(int firstRow,
int lastRow)
Called each time one or more contiguous rows are updated in the underlying TableModel. |
protected void |
tableStructureChanged()
Called each time the structure ( TableColumns, etc) of the underlying TableModel
changes. |
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getColumnName, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt |
| 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, getColumnCount, getColumnName, getValueAt, isCellEditable, removeTableModelListener, setValueAt |
| Methods inherited from interface com.jidesoft.paging.PageNavigationSupport |
|---|
getTotalRecordCount, setTotalRecordCount |
| Constructor Detail |
|---|
public AbstractPageTableModel()
public AbstractPageTableModel(int pageSize)
| Method Detail |
|---|
public int getPageSize()
PageNavigationSupport
getPageSize in interface PageNavigationSupportpublic void setPageSize(int pageSize)
PageNavigationSupport
setPageSize in interface PageNavigationSupportpageSize - the new page size.public int getCurrentPage()
PageNavigationSupport
getCurrentPage in interface PageNavigationSupportpublic void setCurrentPage(int page)
PageNavigationSupport
setCurrentPage in interface PageNavigationSupportpage - the new current page.protected void setPageCount(int pageCount)
public int getPageCount()
PageNavigationSupport
getPageCount in interface PageNavigationSupportpublic void nextPage()
PageNavigationSupport
nextPage in interface PageNavigationSupportpublic void previousPage()
PageNavigationSupport
previousPage in interface PageNavigationSupportpublic void firstPage()
PageNavigationSupport
firstPage in interface PageNavigationSupportpublic void lastPage()
PageNavigationSupport
lastPage in interface PageNavigationSupportpublic void addPageNavigationListener(PageNavigationListener l)
PageNavigationListener to the page.
addPageNavigationListener in interface PageNavigationSupportl - the PageNavigationListener to be addedpublic void removePageNavigationListener(PageNavigationListener l)
PageNavigationListener from the page.
removePageNavigationListener in interface PageNavigationSupportl - the PageNavigationListener to be removedpublic PageNavigationListener[] getPageNavigationListeners()
PageNavigationListeners added to this Page with
addPageNavigationListener .
getPageNavigationListeners in interface PageNavigationSupportPageNavigationListeners added, or an empty array if no listeners have been added
public void firePageNavigationEvent(Object source,
int id,
int oldValue,
int newValue)
PageNavigationListener's PageNavigationEventFired method.
firePageNavigationEvent in interface PageNavigationSupportsource - of this eventid - event id.oldValue - the old value associated with this event.newValue - the new value associated with this event.
protected void pageSizeChanged(int oldPageSize,
int newPageSize)
oldPageSize - the previous page sizenewPageSize - the new page size
protected abstract void pageCountChanged(int oldPageCount,
int newPageCount)
protected abstract void pageIndexChanged(int oldPageIndex,
int newPageIndex)
public int getRowCount()
getRowCount in interface TableModelpublic void tableChanged(TableModelEvent e)
tableChanged in interface TableModelListener
protected void tableRowsInserted(int firstRow,
int lastRow)
TableModel. This
default implementation simply fires a corresponding TableModelEvent to the listeners on this model.
firstRow - the index of the first row that was insertedlastRow - the index of the last row that was inserted
protected void tableRowsDeleted(int firstRow,
int lastRow)
TableModel. This
default implementation simply fires a corresponding TableModelEvent to the listeners on this model.
firstRow - the index of the first row that was deletedlastRow - the index of the last row that was deleted
protected void tableRowsUpdated(int firstRow,
int lastRow)
TableModel. simply fires
a corresponding TableModelEvent to the listeners on this model.
firstRow - the index of the first row that was updatedlastRow - the index of the last row that was updated
public void fireTableCellsUpdated(int firstRow,
int lastRow,
int column)
column in the range [firstRow, lastRow] are
updated. This default implementation simply fires a corresponding TableModelEvent to the listeners
on this model.
firstRow - the index of the first row in the above column that was updatedlastRow - the index of the last row in the above column that was updatedcolumn - the index of the column that was updated
protected void tableCellsUpdated(int column,
int firstRow,
int lastRow)
column in the range [firstRow, lastRow] are
updated. This default implementation simply fires a corresponding TableModelEvent to the listeners
on this model.
column - the index of the column that was updatedfirstRow - the index of the first row in the above column that was updatedlastRow - the index of the last row in the above column that was updatedprotected CompoundTableModelEvent createCompoundTableModelEvent()
protected void tableDataChanged()
TableModel. This
default implementation simply fires a corresponding TableModelEvent to the listeners on this model.
protected void tableStructureChanged()
TableColumns, etc) of the underlying TableModel
changes. This default implementation simply fires a corresponding TableModelEvent to the listeners
on this model.
public void fireTableChanged(TableModelEvent e)
fireTableChanged in class AbstractTableModel
public ConverterContext getConverterContextAt(int rowIndex,
int columnIndex)
ContextSensitiveTableModel
getConverterContextAt in interface ContextSensitiveTableModelrowIndex - the row indexcolumnIndex - the column index
public EditorContext getEditorContextAt(int rowIndex,
int columnIndex)
ContextSensitiveTableModel
getEditorContextAt in interface ContextSensitiveTableModelrowIndex - the row indexcolumnIndex - the column index
public Class<?> getCellClassAt(int rowIndex,
int columnIndex)
ContextSensitiveTableModel
getCellClassAt in interface ContextSensitiveTableModelrowIndex - the row indexcolumnIndex - the column index
public int getColumnType(int columnIndex)
MultiTableModel
getColumnType in interface MultiTableModelcolumnIndex - the column index
public int getTableIndex(int columnIndex)
MultiTableModel
getTableIndex in interface MultiTableModelcolumnIndex - the column index
|
JIDE 3.5.15 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||