@Target(value={TYPE,PACKAGE}) @Retention(value=RUNTIME) @Repeatable(value=NamedNativeQueries.class) public @interface NamedNativeQuery
NamedNativeQuery
with Hibernate features.SQLQuery
Modifier and Type | Required Element and Description |
---|---|
String |
name
The name.
|
String |
query
The SQL query string.
|
Modifier and Type | Optional Element and Description |
---|---|
boolean |
cacheable
Whether the query (results) is cacheable or not.
|
CacheModeType |
cacheMode
The cache mode used for this query.
|
String |
cacheRegion
If the query results are cacheable, name the query cache region to use.
|
boolean |
callable
Does the SQL (
query() ) represent a call to a procedure/function? |
String |
comment
A comment added to the SQL query.
|
int |
fetchSize
The number of rows fetched by the JDBC Driver per trip.
|
FlushModeType |
flushMode
The flush mode for the query.
|
boolean |
readOnly
Whether the results should be read-only.
|
Class |
resultClass
The result Class.
|
String |
resultSetMapping
The name of a SQLResultSetMapping to use.
|
int |
timeout
The query timeout (in seconds).
|
public abstract String name
public abstract String query
public abstract Class resultClass
resultSetMapping()
public abstract String resultSetMapping
resultClass()
.public abstract FlushModeType flushMode
public abstract boolean cacheable
false
, that is not cacheable.public abstract String cacheRegion
public abstract int fetchSize
public abstract int timeout
public abstract boolean callable
query()
) represent a call to a procedure/function?public abstract String comment
public abstract CacheModeType cacheMode
Copyright © 2020 JBoss by Red Hat. All rights reserved.