X - query result typepublic class QueryImpl<X> extends Object implements TypedQuery<X>, org.apache.commons.dbutils.ResultSetHandler<List<X>>, Query
| Constructor and Description |
|---|
QueryImpl(BaseQuery<X> q,
EntityManagerImpl entityManager) |
public QueryImpl(BaseQuery<X> q, EntityManagerImpl entityManager)
q - the criteria queryentityManager - the entity managerpublic int executeUpdate()
executeUpdate in interface Querypublic BaseQuery<X> getCriteriaQuery()
public int getFirstResult()
getFirstResult in interface Querypublic FlushModeType getFlushMode()
getFlushMode in interface Querypublic LockModeType getLockMode()
getLockMode in interface Querypublic int getMaxResults()
getMaxResults in interface Querypublic ParameterExpressionImpl<?> getParameter(int position)
getParameter in interface Querypublic <T> ParameterExpressionImpl<T> getParameter(int position, Class<T> type)
getParameter in interface Querypublic ParameterExpressionImpl<?> getParameter(String name)
getParameter in interface Querypublic <T> Parameter<T> getParameter(String name, Class<T> type)
getParameter in interface Querypublic Set<Parameter<?>> getParameters()
getParameters in interface Querypublic Object getParameterValue(int position)
getParameterValue in interface Querypublic <T> T getParameterValue(Parameter<T> param)
getParameterValue in interface Querypublic Object getParameterValue(String name)
getParameterValue in interface Querypublic List<X> getResultList()
getResultList in interface QuerygetResultList in interface TypedQuery<X>public X getSingleResult()
getSingleResult in interface QuerygetSingleResult in interface TypedQuery<X>public List<X> handle(ResultSet rs) throws SQLException
handle in interface org.apache.commons.dbutils.ResultSetHandler<List<X>>SQLExceptionpublic TypedQuery<X> setFirstResult(int startPosition)
setFirstResult in interface QuerysetFirstResult in interface TypedQuery<X>public QueryImpl<X> setFlushMode(FlushModeType flushMode)
setFlushMode in interface QuerysetFlushMode in interface TypedQuery<X>public TypedQuery<X> setHint(String hintName, Object value)
setHint in interface QuerysetHint in interface TypedQuery<X>public TypedQuery<X> setLockMode(LockModeType lockMode)
setLockMode in interface QuerysetLockMode in interface TypedQuery<X>public TypedQuery<X> setMaxResults(int maxResult)
setMaxResults in interface QuerysetMaxResults in interface TypedQuery<X>public TypedQuery<X> setParameter(int position, Calendar value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(int position, Date value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public QueryImpl<X> setParameter(int position, Object value)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(Parameter<Calendar> param, Calendar value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(Parameter<Date> param, Date value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public <T> TypedQuery<X> setParameter(Parameter<T> param, T value)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(String name, Calendar value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(String name, Date value, TemporalType temporalType)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public TypedQuery<X> setParameter(String name, Object value)
setParameter in interface QuerysetParameter in interface TypedQuery<X>public void storeData(ResultSet rs) throws SQLException
rs - the resultsetSQLException - thrown in case of an underlying SQL ExceptionCopyright © 2012 Batoo Software & Consultancy. All Rights Reserved.