|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectplanetj.database.RowCollection
planetj.database.report.ReportBreakRowCollection
A RowCollection which knows how to generate report breaks.
Nested Class Summary |
Nested classes inherited from class planetj.database.RowCollection |
RowCollection.LinkedRowCollection |
Field Summary |
Fields inherited from class planetj.database.RowCollection |
className, FIRST_ROW, INSERT_ACTION, LAST_ROW, mReturnedFromCache, mRowEventListeners, UPDATE_ACTION |
Constructor Summary | |
ReportBreakRowCollection()
ReportRowCollection constructor comment. |
Method Summary | |
int |
addRows(int pFirstRow,
int pRowCount,
java.sql.ResultSet pRS)
Adds rows from the results set to this RowCollection. |
protected int |
addRows(int pNumberOfRows,
java.sql.ResultSet pRS)
Adds rows from the results set to this RowCollection. |
protected void |
addRunningTotal(ReportBreakCollection reportBreaks)
Stores the report breaks as the running totals for this page of the RC continuum |
protected java.util.List |
extractFieldDescriptors(java.util.List pFieldNames)
Creates a List containing the field descriptors used for this RowCollection |
RowCollection |
getNextRowCollection(int pNumberOfRows)
Gets a RowCollection containing another group of rows which satisfy the query that was used to create this RowCollection. |
RowCollection |
getPreviousRowCollection(int pNumberOfRows)
WK (4/24/2002 9:16:11 AM): Need to reword javadoc, first row is now the number of records per page before the previous row - fixes bug when last row collection doesn't contain the complete number of pages Gets a RowCollection containing another group of rows which satisfy the query that was used to create this RowCollection. |
int |
getReportRowCount()
Gets the number of ReportBreakRows currently contained in this ReportBreakRowCollection. |
static int |
getReportRowCount(RowCollection rc)
Gets the number of ReportBreakRows currently contained in the RowCollection. |
protected ReportBreakCollection |
getRunningTotal(int pageNumber)
Gets the ReportBreakCollection containing the running totals for the specified page of this RC continuum |
protected void |
preprocessRow(Row pRow)
Invoked after a new Row has been read from the DB and just before it's inserted into this RowCollection. |
RowCollection |
refresh()
This method will refresh this RowCollection from the database and return this. |
protected void |
rowCollectionPopulated()
Invoked after all Rows have been read from the DB and added to this RowCollection. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
equals, hashCode |
Constructor Detail |
public ReportBreakRowCollection()
Method Detail |
public int addRows(int pFirstRow, int pRowCount, java.sql.ResultSet pRS) throws CMException
addRows
in class RowCollection
pFirstRow
- The row from the result set which will become row 1 of this RowCollection. The first
row in the result is row number 1. There are two special constants that can be used for this argument:
FIRST_ROW, and LAST_ROW. To add the first ten rows in the result set to this RowCollection you
could invoke this method like this:
addRows (RowCollection.FIRST_ROW, 10, resultSet);
addRows (RowCollection.LAST_ROW - 10, 10, resultSet);
pRowCount
- The number of row from the ResultSet to try and add to this RowCollection. If the special constant
SQLContext.NO_MAXIMUM is passed as this argument, then all the rows in the ResultSet (that aren't before the
row indicated by the pFirstRow parameter) will be added to this RowCollection.pRS
- The result set from which rows will be added.
CMException
protected int addRows(int pNumberOfRows, java.sql.ResultSet pRS) throws CMException
RowCollection
addRows
in class RowCollection
pNumberOfRows
- The number of row to add. The constant SQLContext.ALL_ROWS may also be used.pRS
- The result set from which rows will be added.
CMException
protected void addRunningTotal(ReportBreakCollection reportBreaks)
protected java.util.List extractFieldDescriptors(java.util.List pFieldNames) throws CMException
extractFieldDescriptors
in class RowCollection
CMException
public RowCollection getNextRowCollection(int pNumberOfRows) throws CMException
RowCollection
getNextRowCollection
in class RowCollection
pNumberOfRows
- The number of rows the returned RowCollection should contain. The actual number of rows
it contains may be less than this value (if there weren't enough rows in the database). If there are no
"next rows" an empty RowCollection is returned. The hasNextRowCollection()
method can be used to test for this case.
CMException
public RowCollection getPreviousRowCollection(int pNumberOfRows) throws CMException
RowCollection
pNumberOfRows
before the first row of this
RowCollection, except for cases where there aren't enough "previous rows". In those cases its first row will
be the first row of the ResultSet. So if the first row of this RowCollection is the first row of the
ResultSet, then the returned RowCollection may contain the same rows as this RowCollection. You can use the
hasPreviousRowCollection()
method to check for this case.
If rows in the database have been inserted/deleted/updated between the time this RowCollection was
created and the invocation of this method, it is possible for rows to be duplicated (included in both this
RowCollection and the returned RowCollection) or missing (included in neither).
getPreviousRowCollection
in class RowCollection
pNumberOfRows
- The number of rows the returned RowCollection should contain; the actual number of contained
rows might be fewer if there aren't enough rows in the table.
CMException
public int getReportRowCount()
protected ReportBreakCollection getRunningTotal(int pageNumber)
public static int getReportRowCount(RowCollection rc)
protected void preprocessRow(Row pRow)
preprocessRow
in class RowCollection
public RowCollection refresh() throws CMException
RowCollection
refresh
in class RowCollection
CMException
protected void rowCollectionPopulated()
rowCollectionPopulated
in class RowCollection
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |