public class JRHibernateQueryExecuterFactory extends java.lang.Object implements JRQueryExecuterFactory
JRHibernateQueryExecuter
query executers.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
PARAMETER_HIBERNATE_FILTER_COLLECTION
Built-in parameter used for collection filter queries.
|
static java.lang.String |
PARAMETER_HIBERNATE_SESSION
Built-in parameter holding the value of the Hibernate session to be used for creating the query.
|
static java.lang.String |
PROPERTY_HIBERNATE_CLEAR_CACHE
Property specifying whether hibernate session cache should be cleared between two consecutive fetches when using pagination.
|
static java.lang.String |
PROPERTY_HIBERNATE_FIELD_MAPPING_DESCRIPTIONS
Property specifying whether field descriptions should be used to determine the mapping between the fields
and the query return values.
|
static java.lang.String |
PROPERTY_HIBERNATE_QUERY_LIST_PAGE_SIZE
Property specifying the number of result rows to be retrieved at once when the execution type is list.
|
static java.lang.String |
PROPERTY_HIBERNATE_QUERY_RUN_TYPE
Property specifying the query execution type.
|
static java.lang.String |
QUERY_LANGUAGE_HQL
HQL query language.
|
static java.lang.String |
VALUE_HIBERNATE_QUERY_RUN_TYPE_ITERATE
Value of the
PROPERTY_HIBERNATE_QUERY_RUN_TYPE property
corresponding to iterate execution type. |
static java.lang.String |
VALUE_HIBERNATE_QUERY_RUN_TYPE_LIST
Value of the
PROPERTY_HIBERNATE_QUERY_RUN_TYPE property
corresponding to list execution type. |
static java.lang.String |
VALUE_HIBERNATE_QUERY_RUN_TYPE_SCROLL
Value of the
PROPERTY_HIBERNATE_QUERY_RUN_TYPE property
corresponding to scroll execution type. |
QUERY_EXECUTER_FACTORY_PREFIX
Constructor and Description |
---|
JRHibernateQueryExecuterFactory() |
Modifier and Type | Method and Description |
---|---|
JRQueryExecuter |
createQueryExecuter(JRDataset dataset,
java.util.Map<java.lang.String,? extends JRValueParameter> parameters)
Creates a query executer.
|
java.lang.Object[] |
getBuiltinParameters()
Returns an array containing the
PARAMETER_HIBERNATE_SESSION and
PARAMETER_HIBERNATE_FILTER_COLLECTION parameters. |
boolean |
supportsQueryParameterType(java.lang.String className)
Returns
true for all parameter types. |
public static final java.lang.String QUERY_LANGUAGE_HQL
public static final java.lang.String PARAMETER_HIBERNATE_SESSION
public static final java.lang.String PARAMETER_HIBERNATE_FILTER_COLLECTION
public static final java.lang.String PROPERTY_HIBERNATE_QUERY_RUN_TYPE
org.hibernate.Query.list()
org.hibernate.Query.iterate()
org.hibernate.Query.scroll()
public static final java.lang.String PROPERTY_HIBERNATE_QUERY_LIST_PAGE_SIZE
org.hibernate.Query.setFirstResult()
and org.hibernate.Query.setMaxResults()
.
By default, all the rows are retrieved (no result pagination is performed).public static final java.lang.String PROPERTY_HIBERNATE_CLEAR_CACHE
public static final java.lang.String PROPERTY_HIBERNATE_FIELD_MAPPING_DESCRIPTIONS
public static final java.lang.String VALUE_HIBERNATE_QUERY_RUN_TYPE_LIST
PROPERTY_HIBERNATE_QUERY_RUN_TYPE
property
corresponding to list execution type.public static final java.lang.String VALUE_HIBERNATE_QUERY_RUN_TYPE_ITERATE
PROPERTY_HIBERNATE_QUERY_RUN_TYPE
property
corresponding to iterate execution type.public static final java.lang.String VALUE_HIBERNATE_QUERY_RUN_TYPE_SCROLL
PROPERTY_HIBERNATE_QUERY_RUN_TYPE
property
corresponding to scroll execution type.public java.lang.Object[] getBuiltinParameters()
PARAMETER_HIBERNATE_SESSION
and
PARAMETER_HIBERNATE_FILTER_COLLECTION
parameters.getBuiltinParameters
in interface JRQueryExecuterFactory
public JRQueryExecuter createQueryExecuter(JRDataset dataset, java.util.Map<java.lang.String,? extends JRValueParameter> parameters) throws JRException
JRQueryExecuterFactory
createQueryExecuter
in interface JRQueryExecuterFactory
dataset
- the dataset containing the query, fields, etcparameters
- map of value parameters (instances of JRValueParameter
)
indexed by nameJRException
public boolean supportsQueryParameterType(java.lang.String className)
true
for all parameter types.supportsQueryParameterType
in interface JRQueryExecuterFactory
className
- the value class name of the parameter© 2001-2010 Jaspersoft Corporation www.jaspersoft.com