|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.hibernate.impl.ScrollableResultsImpl
Implementation of the ScrollableResults interface
Constructor Summary | |
ScrollableResultsImpl(ResultSet rs,
PreparedStatement ps,
SessionImplementor sess,
QueryTranslator queryTranslator,
QueryParameters queryParameters,
Type[] types,
Class holderClass)
|
Method Summary | |
void |
afterLast()
Go to a location just after the last result |
void |
beforeFirst()
Go to a location just before first result (this is the initial location) |
void |
close()
Release resources immediately. |
protected JDBCException |
convert(SQLException sqlException,
String message)
|
boolean |
first()
Go to the first result |
Object[] |
get()
Get the current row of results |
Object |
get(int col)
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 big_decimal |
byte[] |
getBinary(int col)
Convenience method to read a binary |
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 or calendar_date |
Character |
getCharacter(int col)
Convenience method to read a character |
Clob |
getClob(int col)
Convenience method to read a clob |
Date |
getDate(int col)
Convenience method to read a date, time or timestamp |
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 location in the result set. |
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 text |
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 i)
Scroll an arbitrary number of locations |
boolean |
setRowNumber(int rowNumber)
Set the current location in the result set, numbered from either the first row (row number 0), or the last row (row number -1). |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ScrollableResultsImpl(ResultSet rs, PreparedStatement ps, SessionImplementor sess, QueryTranslator queryTranslator, QueryParameters queryParameters, Type[] types, Class holderClass) throws MappingException
Method Detail |
public boolean scroll(int i) throws HibernateException
ScrollableResults
scroll
in interface ScrollableResults
i
- a positive (forward) or negative (backward) number of rows
HibernateException
ScrollableResults.scroll(int)
public boolean first() throws HibernateException
ScrollableResults
first
in interface ScrollableResults
HibernateException
ScrollableResults.first()
public boolean last() throws HibernateException
ScrollableResults
last
in interface ScrollableResults
HibernateException
ScrollableResults.last()
public boolean next() throws HibernateException
ScrollableResults
next
in interface ScrollableResults
HibernateException
ScrollableResults.next()
public boolean previous() throws HibernateException
ScrollableResults
previous
in interface ScrollableResults
HibernateException
ScrollableResults.previous()
public Object[] get() throws HibernateException
ScrollableResults
get
in interface ScrollableResults
HibernateException
ScrollableResults.get()
public Object get(int col) throws HibernateException
ScrollableResults
get
in interface ScrollableResults
col
- the column, numbered from zero
HibernateException
ScrollableResults.get(int)
public BigDecimal getBigDecimal(int col) throws HibernateException
ScrollableResults
getBigDecimal
in interface ScrollableResults
HibernateException
ScrollableResults.getBigDecimal(int)
public byte[] getBinary(int col) throws HibernateException
ScrollableResults
getBinary
in interface ScrollableResults
HibernateException
ScrollableResults.getBinary(int)
public String getText(int col) throws HibernateException
ScrollableResults
getText
in interface ScrollableResults
HibernateException
public Blob getBlob(int col) throws HibernateException
ScrollableResults
getBlob
in interface ScrollableResults
HibernateException
ScrollableResults.getBlob(int)
public Clob getClob(int col) throws HibernateException
ScrollableResults
getClob
in interface ScrollableResults
HibernateException
ScrollableResults.getClob(int)
public Boolean getBoolean(int col) throws HibernateException
ScrollableResults
getBoolean
in interface ScrollableResults
HibernateException
ScrollableResults.getBoolean(int)
public Byte getByte(int col) throws HibernateException
ScrollableResults
getByte
in interface ScrollableResults
HibernateException
ScrollableResults.getByte(int)
public Character getCharacter(int col) throws HibernateException
ScrollableResults
getCharacter
in interface ScrollableResults
HibernateException
ScrollableResults.getCharacter(int)
public Date getDate(int col) throws HibernateException
ScrollableResults
getDate
in interface ScrollableResults
HibernateException
ScrollableResults.getDate(int)
public Calendar getCalendar(int col) throws HibernateException
ScrollableResults
getCalendar
in interface ScrollableResults
HibernateException
public Double getDouble(int col) throws HibernateException
ScrollableResults
getDouble
in interface ScrollableResults
HibernateException
ScrollableResults.getDouble(int)
public Float getFloat(int col) throws HibernateException
ScrollableResults
getFloat
in interface ScrollableResults
HibernateException
ScrollableResults.getFloat(int)
public Integer getInteger(int col) throws HibernateException
ScrollableResults
getInteger
in interface ScrollableResults
HibernateException
ScrollableResults.getInteger(int)
public Long getLong(int col) throws HibernateException
ScrollableResults
getLong
in interface ScrollableResults
HibernateException
ScrollableResults.getLong(int)
public Short getShort(int col) throws HibernateException
ScrollableResults
getShort
in interface ScrollableResults
HibernateException
ScrollableResults.getShort(int)
public String getString(int col) throws HibernateException
ScrollableResults
getString
in interface ScrollableResults
HibernateException
ScrollableResults.getString(int)
public void afterLast() throws HibernateException
ScrollableResults
afterLast
in interface ScrollableResults
HibernateException
ScrollableResults.afterLast()
public void beforeFirst() throws HibernateException
ScrollableResults
beforeFirst
in interface ScrollableResults
HibernateException
ScrollableResults.beforeFirst()
public void close() throws HibernateException
ScrollableResults
close
in interface ScrollableResults
HibernateException
ScrollableResults.close()
public Locale getLocale(int col) throws HibernateException
ScrollableResults
getLocale
in interface ScrollableResults
HibernateException
ScrollableResults.getLocale(int)
public TimeZone getTimeZone(int col) throws HibernateException
ScrollableResults
getTimeZone
in interface ScrollableResults
HibernateException
ScrollableResults.getTimeZone(int)
public Type getType(int i)
ScrollableResults
getType
in interface ScrollableResults
i
- the column, numbered from zero
ScrollableResults.getType(int)
public boolean isFirst() throws HibernateException
ScrollableResults
isFirst
in interface ScrollableResults
HibernateException
ScrollableResults.isFirst()
public boolean isLast() throws HibernateException
ScrollableResults
isLast
in interface ScrollableResults
HibernateException
ScrollableResults.isLast()
public int getRowNumber() throws HibernateException
ScrollableResults
getRowNumber
in interface ScrollableResults
HibernateException
public boolean setRowNumber(int rowNumber) throws HibernateException
ScrollableResults
setRowNumber
in interface ScrollableResults
rowNumber
- the row number, numbered from the last row, in the
case of a negative row number
HibernateException
protected JDBCException convert(SQLException sqlException, String message)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |