public class CachingQueryService extends Object implements QueryService
Constructor and Description |
---|
CachingQueryService(QueryService wrappedService)
Construct the CachingQueryDAO with a wrapped QueryDAO.
|
Modifier and Type | Method and Description |
---|---|
QueryResult |
executeQuery(QueryConstructor queryConstructor,
ResultFilter resultFilter)
This executes the actual broker query based on the constructed query and resultFilter.
|
QueryResult |
executeQuery(String selectField,
Criteria criteria,
Sorting sorting,
ResultFilter resultFilter)
This executes the actual broker query based on the given criteria, sorting and filter.
|
QueryConstructor |
generateQuery(String selectField,
Criteria criteria,
Sorting sorting)
This generates the main broker query needed to execute the JPQL query.
|
String |
getStorageId()
Returns the storageId that the queryService will query.
|
public CachingQueryService(QueryService wrappedService)
wrappedService
- The DAO of type QueryDAOpublic String getStorageId()
QueryService
getStorageId
in interface QueryService
public QueryResult executeQuery(String selectField, Criteria criteria, Sorting sorting, ResultFilter resultFilter) throws StorageException
QueryService
executeQuery
in interface QueryService
selectField
- The default query field to selectcriteria
- The criteria to use for the broker querysorting
- The sort conditions to applyresultFilter
- The filter to apply to the end resultsStorageException
- If unable to execute the broker querypublic QueryResult executeQuery(QueryConstructor queryConstructor, ResultFilter resultFilter) throws StorageException
QueryService
executeQuery
in interface QueryService
queryConstructor
- The constructed QueryresultFilter
- The filter to apply to the end resultsStorageException
- If unable to execute the broker querypublic QueryConstructor generateQuery(String selectField, Criteria criteria, Sorting sorting) throws StorageException
QueryService
generateQuery
in interface QueryService
selectField
- The selected fieldcriteria
- The criteria to use for the broker querysorting
- The sorting to apply to the query resultsStorageException
- If unable to generate a broker queryCopyright (c) 2014-2021 All Rights Reserved by the RWS Group for and on behalf of its affiliates and subsidiaries