private static class PresortCompoundQuery.CursorResults extends java.lang.Object implements Results
Modifier and Type | Field and Description |
---|---|
private Cursor |
cursor
Backing cursor
|
private java.lang.Object[] |
row
Array of records which represents the current, virtual row
|
Constructor and Description |
---|
CursorResults(Cursor cursor)
Constructor which accepts the backing cursor object.
|
Modifier and Type | Method and Description |
---|---|
void |
cleanup()
Clean up and release any resources which this object is holding, such
as open result sets.
|
boolean |
first()
Move cursor to the first results row.
|
java.lang.Object[] |
get()
Get the array of objects at the current result row.
|
java.lang.Object |
get(int column)
Get the object at the current result row, at the specified column.
|
java.io.Serializable |
getID(int column)
Get the primary key ID at the current result row, at the specified
column.
|
int |
getRowNumber()
Get the row number currently under the cursor.
|
boolean |
isFirst()
Is the cursor on the first row in the results set?
|
boolean |
isLast()
Is the cursor on the last row in the results set?
|
boolean |
last()
Move cursor to the last results row.
|
boolean |
next()
Move cursor to the next results row.
|
boolean |
previous()
Move cursor to the previous results row.
|
void |
reset()
Reset the cursor to its natural starting position, before the first
result row.
|
boolean |
scroll(int rows)
Scroll the cursor ahead by the specified number of rows.
|
void |
sessionClosing()
Invoked when the current Hibernate session is about to close.
|
boolean |
setRowNumber(int row)
Set the row number currently under the cursor.
|
private final Cursor cursor
private java.lang.Object[] row
CursorResults(Cursor cursor)
cursor
- Cursor which backs this Results
object.public boolean first()
public boolean last()
public boolean next()
public boolean previous()
public boolean isFirst()
public boolean isLast()
public java.lang.Object[] get()
public java.lang.Object get(int column)
public java.io.Serializable getID(int column)
public int getRowNumber()
getRowNumber
in interface Results
-1
if the cursor is not currently on a result.public boolean setRowNumber(int row)
setRowNumber
in interface Results
row
- Zero-based index of the row to be set as the current row.true
if there is a row at the specified row
number; else false
.java.lang.UnsupportedOperationException
- always; this method is not needed to sort results.public boolean scroll(int rows)
public void reset()
public void sessionClosing()
This implementation does nothing.
sessionClosing
in interface Results