public class QueryImpl<R> extends AbstractProducedQuery<R> implements Query<R>
Constructor and Description |
---|
QueryImpl(SharedSessionContractImplementor producer,
ParameterMetadata parameterMetadata,
String queryString) |
Modifier and Type | Method and Description |
---|---|
protected QueryParameterBindings |
getQueryParameterBindings() |
String |
getQueryString()
Get the query string.
|
String[] |
getReturnAliases() |
Type[] |
getReturnTypes()
Return the Hibernate types of the query results.
|
protected boolean |
isNativeQuery()
Is the query represented here a native (SQL) query?
|
Query |
setEntity(int position,
Object val)
Bind an instance of a mapped persistent class to a JDBC-style query parameter.
|
Query |
setEntity(String name,
Object val)
Bind an instance of a mapped persistent class to a named query parameter.
|
addQueryHint, afterQuery, applyAliasSpecificLockModeHint, applyCacheableHint, applyCacheModeHint, applyCacheRegionHint, applyCommentHint, applyEntityGraphQueryHint, applyFetchSizeHint, applyFlushModeHint, applyFollowOnLockingHint, applyHibernateLockModeHint, applyJpaCacheRetrieveMode, applyJpaCacheStoreMode, applyLockModeTypeHint, applyLockTimeoutHint, applyNativeQueryLockMode, applyPassDistinctThrough, applyReadOnlyHint, applyTimeoutHint, beforeQuery, canApplyAliasSpecificLockModeHints, collectBaselineHints, collectHints, determineProperBooleanType, determineProperBooleanType, determineType, doExecuteUpdate, doIterate, doList, doScroll, executeUpdate, getCacheMode, getCacheRegion, getComment, getExceptionConverter, getFetchSize, getFirstResult, getFlushMode, getHibernateFlushMode, getHints, getLockMode, getLockOptions, getMaxResults, getNamedParameterMap, getNamedParameters, getParameter, getParameter, getParameter, getParameter, getParameterMetadata, getParameters, getParameterValue, getParameterValue, getParameterValue, getPositionalParameterTypes, getPositionalParameterValues, getProducer, getQueryOptions, getQueryParameters, getSingleResult, getSupportedHints, getTimeout, handleUnrecognizedHint, isBound, isCacheable, isCallable, isReadOnly, iterate, list, makeQueryParametersForExecution, putIfNotNull, putIfNotNull, resolveEntityName, scroll, scroll, setCacheable, setCacheMode, setCacheRegion, setComment, setFetchSize, setFirstResult, setFlushMode, setFlushMode, setHibernateFlushMode, setHint, setLockMode, setLockMode, setLockOptions, setMaxResults, setOptionalEntityName, setOptionalId, setOptionalObject, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setProperties, setProperties, setReadOnly, setResultTransformer, setTimeout, stream, uniqueElement, uniqueResult, uniqueResultOptional, unwrap
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addQueryHint, getCacheMode, getCacheRegion, getComment, getFetchSize, getHibernateFlushMode, getLockOptions, getParameterMetadata, getProducer, getResultList, getResultStream, getSingleResult, list, scroll, scroll, setBigDecimal, setBigDecimal, setBigInteger, setBigInteger, setBinary, setBinary, setBoolean, setBoolean, setByte, setByte, setCacheable, setCacheMode, setCacheRegion, setCalendar, setCalendar, setCalendarDate, setCalendarDate, setCharacter, setCharacter, setComment, setDate, setDate, setDouble, setDouble, setFetchSize, setFirstResult, setFloat, setFloat, setFlushMode, setFlushMode, setHibernateFlushMode, setHint, setInteger, setInteger, setLocale, setLocale, setLockMode, setLockMode, setLockOptions, setLong, setLong, setMaxResults, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameter, setParameterList, setParameterList, setParameterList, setParameterList, setParameterList, setParameters, setProperties, setProperties, setReadOnly, setResultTransformer, setSerializable, setSerializable, setShort, setShort, setString, setString, setText, setText, setTime, setTime, setTimeout, setTimestamp, setTimestamp, stream, uniqueResult, uniqueResultOptional
determineProperBooleanType, determineProperBooleanType, getFlushMode, getHibernateFirstResult, getHibernateMaxResults, getNamedParameters, getQueryOptions, getTimeout, isCacheable, isReadOnly, iterate, setHibernateFirstResult, setHibernateMaxResults, setParameterList, setParameterList, setParameterList, setParameterList
executeUpdate, getFirstResult, getHints, getLockMode, getMaxResults, getParameter, getParameter, getParameter, getParameter, getParameters, getParameterValue, getParameterValue, getParameterValue, isBound, unwrap
public QueryImpl(SharedSessionContractImplementor producer, ParameterMetadata parameterMetadata, String queryString)
protected QueryParameterBindings getQueryParameterBindings()
getQueryParameterBindings
in class AbstractProducedQuery<R>
public String getQueryString()
Query
protected boolean isNativeQuery()
AbstractProducedQuery
isNativeQuery
in class AbstractProducedQuery<R>
true
if it is a native query; false
otherwisepublic Type[] getReturnTypes()
Query
getReturnTypes
in interface BasicQueryContract<CommonQueryContract>
public String[] getReturnAliases()
public Query setEntity(int position, Object val)
Query
Query.setParameter(int, Object)
for null values.position
- the position of the parameter in the query
string, numbered from 0.val
- a non-null instance of a persistent classthis
, for method chainingpublic Query setEntity(String name, Object val)
Query
Query.setParameter(String, Object)
for null values.name
- the name of the parameterval
- a non-null instance of a persistent classthis
, for method chainingCopyright © 2019 JBoss by Red Hat. All rights reserved.