类 AbstractScrollableResults
- java.lang.Object
-
- org.hibernate.internal.AbstractScrollableResults
-
public abstract class AbstractScrollableResults extends Object implements ScrollableResultsImplementor
Base implementation of the ScrollableResults interface.- 作者:
- Steve Ebersole
-
-
构造器概要
构造器 限定符 构造器 说明 protectedAbstractScrollableResults(ResultSet rs, PreparedStatement ps, SharedSessionContractImplementor sess, Loader loader, QueryParameters queryParameters, Type[] types, HolderInstantiator holderInstantiator)
-
方法概要
所有方法 实例方法 抽象方法 具体方法 修饰符和类型 方法 说明 protected voidafterScrollOperation()voidclose()Release resources immediately.Object[]get()Get the current row of results.Objectget(int col)Get the ith object in the current row of results, without initializing any other results in the row.BigDecimalgetBigDecimal(int col)Convenience method to read a BigDecimal.BigIntegergetBigInteger(int col)Convenience method to read a BigInteger.byte[]getBinary(int col)Convenience method to read a binary (byte[]).BlobgetBlob(int col)Convenience method to read a blob.BooleangetBoolean(int col)Convenience method to read a boolean.BytegetByte(int col)Convenience method to read a byte.CalendargetCalendar(int col)Convenience method to read a Calendar.CharactergetCharacter(int col)Convenience method to read a char.ClobgetClob(int col)Convenience method to read a clob.protected abstract Object[]getCurrentRow()DategetDate(int col)Convenience method to read a Date.DoublegetDouble(int col)Convenience method to read a double.protected ObjectgetFinal(int col, Type returnType)Check that the requested type is compatible with the result type, and return the column value.FloatgetFloat(int col)Convenience method to read a float.protected HolderInstantiatorgetHolderInstantiator()IntegergetInteger(int col)Convenience method to read an integer.protected LoadergetLoader()LocalegetLocale(int col)Convenience method to read a Locale.LonggetLong(int col)Convenience method to read a long.protected ObjectgetNonFinal(int col, Type returnType)Check that the requested type is compatible with the result type, and return the column value.intgetNumberOfTypes()protected PreparedStatementgetPs()protected QueryParametersgetQueryParameters()protected ResultSetgetResultSet()protected SharedSessionContractImplementorgetSession()ShortgetShort(int col)Convenience method to read a short.StringgetString(int col)Convenience method to read a string.StringgetText(int col)Convenience method to read a String using streaming.TimeZonegetTimeZone(int col)Convenience method to read a TimeZone.TypegetType(int i)Get the type of the ith column of results.protected Type[]getTypes()booleanisClosed()-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 org.hibernate.ScrollableResults
afterLast, beforeFirst, first, getRowNumber, isFirst, isLast, last, next, previous, scroll, setRowNumber
-
-
-
-
构造器详细资料
-
AbstractScrollableResults
protected AbstractScrollableResults(ResultSet rs, PreparedStatement ps, SharedSessionContractImplementor sess, Loader loader, QueryParameters queryParameters, Type[] types, HolderInstantiator holderInstantiator)
-
-
方法详细资料
-
getCurrentRow
protected abstract Object[] getCurrentRow()
-
getResultSet
protected ResultSet getResultSet()
-
getPs
protected PreparedStatement getPs()
-
getSession
protected SharedSessionContractImplementor getSession()
-
getLoader
protected Loader getLoader()
-
getQueryParameters
protected QueryParameters getQueryParameters()
-
getTypes
protected Type[] getTypes()
-
getHolderInstantiator
protected HolderInstantiator getHolderInstantiator()
-
close
public final void close()
从接口复制的说明:ScrollableResultsRelease resources immediately.- 指定者:
close在接口中AutoCloseable- 指定者:
close在接口中Closeable- 指定者:
close在接口中ScrollableResults
-
isClosed
public boolean isClosed()
- 指定者:
isClosed在接口中ScrollableResultsImplementor
-
getNumberOfTypes
public int getNumberOfTypes()
- 指定者:
getNumberOfTypes在接口中ScrollableResultsImplementor
-
get
public final Object[] get() throws HibernateException
从接口复制的说明:ScrollableResultsGet the current row of results.- 指定者:
get在接口中ScrollableResults- 返回:
- The array of results
- 抛出:
HibernateException
-
get
public final Object get(int col) throws HibernateException
从接口复制的说明:ScrollableResultsGet the ith object in the current row of results, without initializing any other results in the row. This method may be used safely, regardless of the type of the column (ie. even for scalar results).- 指定者:
get在接口中ScrollableResults- 参数:
col- the column, numbered from zero- 返回:
- The requested result object; may return
null - 抛出:
HibernateException
-
getFinal
protected final Object getFinal(int col, Type returnType) throws HibernateException
Check that the requested type is compatible with the result type, and return the column value. This version makes sure the the classes are identical.- 参数:
col- the columnreturnType- a "final" type- 抛出:
HibernateException
-
getNonFinal
protected final Object getNonFinal(int col, Type returnType) throws HibernateException
Check that the requested type is compatible with the result type, and return the column value. This version makes sure the the classes are "assignable".- 参数:
col- the columnreturnType- any type- 抛出:
HibernateException
-
getBigDecimal
public final BigDecimal getBigDecimal(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a BigDecimal.- 指定者:
getBigDecimal在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a BigDecimal
- 抛出:
HibernateException
-
getBigInteger
public final BigInteger getBigInteger(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a BigInteger.- 指定者:
getBigInteger在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a BigInteger
- 抛出:
HibernateException
-
getBinary
public final byte[] getBinary(int col) throws HibernateException从接口复制的说明:ScrollableResultsConvenience method to read a binary (byte[]).- 指定者:
getBinary在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a binary (byte[])
- 抛出:
HibernateException
-
getText
public final String getText(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a String using streaming.- 指定者:
getText在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a String
- 抛出:
HibernateException
-
getBlob
public final Blob getBlob(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a blob.- 指定者:
getBlob在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a Blob
- 抛出:
HibernateException
-
getClob
public final Clob getClob(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a clob.- 指定者:
getClob在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a Clob
- 抛出:
HibernateException
-
getBoolean
public final Boolean getBoolean(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a boolean.- 指定者:
getBoolean在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a boolean
- 抛出:
HibernateException
-
getByte
public final Byte getByte(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a byte.- 指定者:
getByte在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a byte
- 抛出:
HibernateException
-
getCharacter
public final Character getCharacter(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a char.- 指定者:
getCharacter在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a char
- 抛出:
HibernateException
-
getDate
public final Date getDate(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a Date.- 指定者:
getDate在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a Date
- 抛出:
HibernateException
-
getCalendar
public final Calendar getCalendar(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a Calendar.- 指定者:
getCalendar在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a Calendar
- 抛出:
HibernateException
-
getDouble
public final Double getDouble(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a double.- 指定者:
getDouble在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a double
- 抛出:
HibernateException
-
getFloat
public final Float getFloat(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a float.- 指定者:
getFloat在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a float
- 抛出:
HibernateException
-
getInteger
public final Integer getInteger(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read an integer.- 指定者:
getInteger在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as an integer
- 抛出:
HibernateException
-
getLong
public final Long getLong(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a long.- 指定者:
getLong在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a long
- 抛出:
HibernateException
-
getShort
public final Short getShort(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a short.- 指定者:
getShort在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a short
- 抛出:
HibernateException
-
getString
public final String getString(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a string.- 指定者:
getString在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a String
- 抛出:
HibernateException
-
getLocale
public final Locale getLocale(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a Locale.- 指定者:
getLocale在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a Locale
- 抛出:
HibernateException
-
getTimeZone
public final TimeZone getTimeZone(int col) throws HibernateException
从接口复制的说明:ScrollableResultsConvenience method to read a TimeZone.- 指定者:
getTimeZone在接口中ScrollableResults- 参数:
col- The column, numbered from zero- 返回:
- The column value as a TimeZone
- 抛出:
HibernateException
-
getType
public final Type getType(int i)
从接口复制的说明:ScrollableResultsGet the type of the ith column of results.- 指定者:
getType在接口中ScrollableResults- 参数:
i- the column, numbered from zero- 返回:
- the Hibernate type
-
afterScrollOperation
protected void afterScrollOperation()
-
-