public interface ScrollableResults extends Closeable
Query.scroll()
Modifier and Type | Method and Description |
---|---|
void |
afterLast()
Go to a location just after the last result.
|
void |
beforeFirst()
Go to a location just before first result, This is the location of the cursor on a newly returned
scrollable result.
|
void |
close()
Release resources immediately.
|
boolean |
first()
Go to the first result.
|
Object[] |
get()
Get the current row of results.
|
Object |
get(int i)
Get the ith object in the current row of results, without
initializing any other results in the row.
|
BigDecimal |
getBigDecimal(int col)
Convenience method to read a BigDecimal.
|
BigInteger |
getBigInteger(int col)
Convenience method to read a BigInteger.
|
byte[] |
getBinary(int col)
Convenience method to read a binary (byte[]).
|
Blob |
getBlob(int col)
Convenience method to read a blob.
|
Boolean |
getBoolean(int col)
Convenience method to read a boolean.
|
Byte |
getByte(int col)
Convenience method to read a byte.
|
Calendar |
getCalendar(int col)
Convenience method to read a Calendar.
|
Character |
getCharacter(int col)
Convenience method to read a char.
|
Clob |
getClob(int col)
Convenience method to read a clob.
|
Date |
getDate(int col)
Convenience method to read a Date.
|
Double |
getDouble(int col)
Convenience method to read a double.
|
Float |
getFloat(int col)
Convenience method to read a float.
|
Integer |
getInteger(int col)
Convenience method to read an integer.
|
Locale |
getLocale(int col)
Convenience method to read a Locale.
|
Long |
getLong(int col)
Convenience method to read a long.
|
int |
getRowNumber()
Get the current position in the results.
|
Short |
getShort(int col)
Convenience method to read a short.
|
String |
getString(int col)
Convenience method to read a string.
|
String |
getText(int col)
Convenience method to read a String using streaming.
|
TimeZone |
getTimeZone(int col)
Convenience method to read a TimeZone.
|
Type |
getType(int i)
Get the type of the ith column of results.
|
boolean |
isFirst()
Is this the first result?
|
boolean |
isLast()
Is this the last result?
|
boolean |
last()
Go to the last result.
|
boolean |
next()
Advance to the next result.
|
boolean |
previous()
Retreat to the previous result.
|
boolean |
scroll(int positions)
Scroll the specified number of positions from the current position.
|
boolean |
setRowNumber(int rowNumber)
Set the current position in the result set.
|
boolean next()
true
if there is another resultboolean previous()
true
if there is a previous resultboolean scroll(int positions)
positions
- a positive (forward) or negative (backward) number of rowstrue
if there is a result at the new locationboolean last()
true
if there are any resultsboolean first()
true
if there are any resultsvoid beforeFirst()
void afterLast()
boolean isFirst()
true
if this is the first row of results, otherwise false
boolean isLast()
true
if this is the last row of results.int getRowNumber()
boolean setRowNumber(int rowNumber)
rowNumber
- the row number. A positive number indicates a value numbered from the first row; a
negative number indicates a value numbered from the last row.void close()
close
in interface AutoCloseable
close
in interface Closeable
Object[] get()
Object get(int i)
i
- the column, numbered from zeronull
IndexOutOfBoundsException
- If i is an invalid index.Type getType(int i)
i
- the column, numbered from zeroIndexOutOfBoundsException
- If i is an invalid index.Integer getInteger(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Long getLong(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Float getFloat(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Boolean getBoolean(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Double getDouble(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Short getShort(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Byte getByte(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Character getCharacter(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.byte[] getBinary(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.String getText(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Blob getBlob(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Clob getClob(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.String getString(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.BigDecimal getBigDecimal(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.BigInteger getBigInteger(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Date getDate(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Locale getLocale(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Calendar getCalendar(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.TimeZone getTimeZone(int col)
col
- The column, numbered from zeroIndexOutOfBoundsException
- If col is an invalid index.Copyright © 2001-2017 Red Hat, Inc. All Rights Reserved.