public abstract class ReportTableModel
extends java.lang.Object
reset(); // move internal "pointer" before first row
while (hasMoreRows()){ // check if there is a next row
selectNextRow(); // select next row
getCell(columnNameA); // get content of a cell by name A
getCell(columnNameB); // get content of a cell by name B
}
disposeData();
Constructor and Description |
---|
ReportTableModel() |
Modifier and Type | Method and Description |
---|---|
abstract java.lang.String[] |
definedColumns()
Gets all table columns of this model.
|
void |
disposeData()
This methods is finally called if this model is not longer used.
|
protected void |
doDisposeData() |
protected abstract java.lang.Object |
doGetValueOfCell(java.lang.String columnName) |
protected abstract void |
doReset() |
protected abstract void |
doSelectNextRow() |
protected org.apache.commons.logging.Log |
getLogger() |
int |
getRowIndex() |
java.lang.Object |
getValueOfCell(java.lang.String columnName)
Gets the value of a cell of the current selected row.
|
abstract boolean |
hasMoreRows()
Determinates if more rows are available.
|
void |
reset()
Reset this model.
|
void |
selectNextRow()
Select the next row.
|
public abstract java.lang.String[] definedColumns()
public final void disposeData() throws ReportException
ReportException
public final void reset() throws ReportException
ReportException
public final void selectNextRow() throws ReportException
ReportException
protected void doDisposeData() throws ReportException
ReportException
protected abstract java.lang.Object doGetValueOfCell(java.lang.String columnName) throws ReportException
ReportException
protected abstract void doReset() throws ReportException
ReportException
protected abstract void doSelectNextRow() throws ReportException
ReportException
public final int getRowIndex()
public final java.lang.Object getValueOfCell(java.lang.String columnName) throws ReportException
columnName
- Name of column.ReportException
protected org.apache.commons.logging.Log getLogger()
public abstract boolean hasMoreRows() throws ReportException
ReportException
© 2003-2011 by Sascha Schmidt (vision-cloud.de). All Rights Reserved.