站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Hibernate 2.1.8 正式版 API 英文文档

SQLQueryImpl (Hibernate API Documentation) - Hibernate 2.1.8 正式版 API 英文文档


net.sf.hibernate.impl
Class SQLQueryImpl

java.lang.Object
  extended bynet.sf.hibernate.impl.AbstractQueryImpl
      extended bynet.sf.hibernate.impl.SQLQueryImpl
All Implemented Interfaces:
Query

public class SQLQueryImpl
extends AbstractQueryImpl

Implements SQL query passthrough.

 
 
   SELECT {person}.NAME AS {person.name}, {person}.AGE AS {person.age}, {person}.SEX AS {person.sex}
   FROM PERSON {person} WHERE {person}.NAME LIKE 'Hiber%'
 
 

Author:
Max Andersen

Method Summary
 String[] getReturnAliases()
           
 Class[] getReturnClasses()
           
 Type[] getReturnTypes()
          Return the Hibernate types of the query result set.
 Iterator iterate()
          Return the query results as an Iterator.
 List list()
          Return the query results as a List.
 ScrollableResults scroll()
          Return the query results as ScrollableResults.
 ScrollableResults scroll(ScrollMode scrollMode)
          Return the query results as ScrollableResults.
 
Methods inherited from class net.sf.hibernate.impl.AbstractQueryImpl
bindParameterLists, getNamedParameterLists, getNamedParameters, getNamedParams, getQueryParameters, getQueryString, getRowSelection, getSelection, getTypes, getValues, setBigDecimal, setBigDecimal, setBinary, setBinary, setBoolean, setBoolean, setByte, setByte, setCacheable, setCacheRegion, setCalendar, setCalendar, setCalendarDate, setCalendarDate, setCharacter, setCharacter, setDate, setDate, setDouble, setDouble, setEntity, setEntity, setEnum, setEnum, setFetchSize, setFirstResult, setFloat, setFloat, setForceCacheRefresh, setInteger, setInteger, setLocale, setLocale, setLockMode, setLong, setLong, setMaxResults, setParameter, setParameter, setParameter, setParameter, setParameterList, setParameterList, setParameterList, setParameterList, setProperties, setSerializable, setSerializable, setShort, setShort, setString, setString, setText, setText, setTime, setTime, setTimeout, setTimestamp, setTimestamp, typeArray, uniqueResult, valueArray, verifyParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getReturnAliases

public String[] getReturnAliases()

getReturnClasses

public Class[] getReturnClasses()

list

public List list()
          throws HibernateException
Description copied from interface: Query
Return the query results as a List. If the query contains multiple results pre row, the results are returned in an instance of Object[].

Returns:
the result list
Throws:
HibernateException

iterate

public Iterator iterate()
                 throws HibernateException
Description copied from interface: Query
Return the query results as an Iterator. If the query contains multiple results pre row, the results are returned in an instance of Object[].

Entities returned as results are initialized on demand. The first SQL query returns identifiers only.

Returns:
the result iterator
Throws:
HibernateException

scroll

public ScrollableResults scroll()
                         throws HibernateException
Description copied from interface: Query
Return the query results as ScrollableResults. The scrollability of the returned results depends upon JDBC driver support for scrollable ResultSets.

Entities returned as results are initialized on demand. The first SQL query returns identifier only.

Returns:
the result iterator
Throws:
HibernateException
See Also:
ScrollableResults

scroll

public ScrollableResults scroll(ScrollMode scrollMode)
                         throws HibernateException
Description copied from interface: Query
Return the query results as ScrollableResults. The scrollability of the returned results depends upon JDBC driver support for scrollable ResultSets.

Returns:
the result iterator
Throws:
HibernateException
See Also:
ScrollableResults, ScrollMode

getReturnTypes

public Type[] getReturnTypes()
                      throws HibernateException
Description copied from interface: Query
Return the Hibernate types of the query result set.

Specified by:
getReturnTypes in interface Query
Overrides:
getReturnTypes in class AbstractQueryImpl
Throws:
HibernateException