public class NamedQueryDefinition extends Object implements Serializable
Constructor and Description |
---|
NamedQueryDefinition(String name,
String query,
boolean cacheable,
String cacheRegion,
Integer timeout,
Integer fetchSize,
FlushMode flushMode,
CacheMode cacheMode,
boolean readOnly,
String comment,
Map parameterTypes)
Deprecated.
Use
NamedQueryDefinitionBuilder instead. |
NamedQueryDefinition(String name,
String query,
boolean cacheable,
String cacheRegion,
Integer timeout,
Integer lockTimeout,
Integer fetchSize,
FlushMode flushMode,
CacheMode cacheMode,
boolean readOnly,
String comment,
Map parameterTypes)
Deprecated.
Use
NamedQueryDefinitionBuilder instead. |
Modifier and Type | Method and Description |
---|---|
CacheMode |
getCacheMode() |
String |
getCacheRegion() |
String |
getComment() |
Integer |
getFetchSize() |
Integer |
getFirstResult() |
FlushMode |
getFlushMode() |
LockOptions |
getLockOptions() |
Integer |
getMaxResults() |
String |
getName() |
Map |
getParameterTypes() |
String |
getQuery() |
String |
getQueryString() |
Integer |
getTimeout() |
boolean |
isCacheable() |
boolean |
isReadOnly() |
NamedQueryDefinition |
makeCopy(String name) |
String |
toString() |
@Deprecated public NamedQueryDefinition(String name, String query, boolean cacheable, String cacheRegion, Integer timeout, Integer fetchSize, FlushMode flushMode, CacheMode cacheMode, boolean readOnly, String comment, Map parameterTypes)
NamedQueryDefinitionBuilder
instead.hbm.xml
files and
NamedQuery
annotation.name
- The name under which to key/register the queryquery
- The query string.cacheable
- Is the query cacheable?cacheRegion
- If cacheable, was there a specific region named?timeout
- Query timeout, null
indicates no timeoutfetchSize
- Fetch size associated with the query, null
indicates no limitflushMode
- Flush mode associated with querycacheMode
- Cache mode associated with queryreadOnly
- Should entities returned from this query (those not already associated with the Session anyway)
be loaded as read-only?comment
- SQL comment to be used in the generated SQL, null
indicates noneparameterTypes
- (no idea, afaict this is always passed as null)@Deprecated public NamedQueryDefinition(String name, String query, boolean cacheable, String cacheRegion, Integer timeout, Integer lockTimeout, Integer fetchSize, FlushMode flushMode, CacheMode cacheMode, boolean readOnly, String comment, Map parameterTypes)
NamedQueryDefinitionBuilder
instead.NamedQuery
.name
- The name under which to key/register the queryquery
- The query string.cacheable
- Is the query cacheable?cacheRegion
- If cacheable, was there a specific region named?timeout
- Query timeout, null
indicates no timeoutlockTimeout
- Specifies the lock timeout for queries that apply lock modes.fetchSize
- Fetch size associated with the query, null
indicates no limitflushMode
- Flush mode associated with querycacheMode
- Cache mode associated with queryreadOnly
- Should entities returned from this query (those not already associated with the Session anyway)
be loaded as read-only?comment
- SQL comment to be used in the generated SQL, null
indicates noneparameterTypes
- (no idea, afaict this is always passed as null)public String getName()
public String getQueryString()
public boolean isCacheable()
public String getCacheRegion()
public Integer getFetchSize()
public Integer getTimeout()
public FlushMode getFlushMode()
public Map getParameterTypes()
public String getQuery()
public CacheMode getCacheMode()
public boolean isReadOnly()
public String getComment()
public LockOptions getLockOptions()
public Integer getFirstResult()
public Integer getMaxResults()
public NamedQueryDefinition makeCopy(String name)
Copyright © 2019 JBoss by Red Hat. All rights reserved.