|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.rice.krad.uif.service.impl.AttributeQueryServiceImpl
public class AttributeQueryServiceImpl
Implementation of AttributeQueryService
that prepares the attribute queries and
delegates to the LookupService
Constructor Summary | |
---|---|
AttributeQueryServiceImpl()
|
Method Summary | |
---|---|
protected Collection<?> |
executeAttributeQueryCriteria(AttributeQuery attributeQuery,
Map<String,String> queryParameters,
Map<String,String> additionalCriteria)
Prepares a query using the configured data object, parameters, and criteria, then executes the query and returns the result Collection |
protected Object |
executeAttributeQueryMethod(View view,
AttributeQuery attributeQuery,
Map<String,String> queryParameters,
boolean isSuggestQuery,
String queryTerm)
Prepares the method configured on the attribute query then performs the method invocation |
protected ConfigurationService |
getConfigurationService()
Gets the configuration service |
protected LookupService |
getLookupService()
Gets the lookup service |
AttributeQueryResult |
performFieldQuery(View view,
String fieldId,
Map<String,String> queryParameters)
Executes the AttributeQuery associated with the field given by the id. |
AttributeQueryResult |
performFieldSuggestQuery(View view,
String fieldId,
String fieldTerm,
Map<String,String> queryParameters)
Executes the AttributeQuery associated with the Suggest widget within
the field given by the Id. |
protected void |
retrievePropertiesOnResults(AttributeQueryResult queryResult,
Collection<?> results,
Suggest fieldSuggest)
Instead of returning the full object this method fills in queryResult with data that contain the properties of each result object, as configured through the fieldSuggest, from the set of results. |
void |
setConfigurationService(ConfigurationService configurationService)
Sets the configuration service |
void |
setLookupService(LookupService lookupService)
Sets the lookup service |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AttributeQueryServiceImpl()
Method Detail |
---|
public AttributeQueryResult performFieldSuggestQuery(View view, String fieldId, String fieldTerm, Map<String,String> queryParameters)
AttributeQueryService
AttributeQuery
associated with the Suggest
widget within
the field given by the Id. The given Map of key/value pairs are used to populate the criteria part of the
attribute query or as arguments to the query method. The fieldTerm parameter gives the current value
of the field that should be matched on. The query is expected to return a list of values to suggest
performFieldSuggestQuery
in interface AttributeQueryService
view
- - view instance for which the field belongsfieldId
- - id for the attribute field to perform the query forfieldTerm
- - the partial value of the query field to matchqueryParameters
- - map of key/value pairs that are parameters to the query
org.kuali.rice.krad.uif.service.AttributeQueryService#performFieldSuggestQuery(
org.kuali.rice.krad.uif.view.View, java.lang.String, java.lang.String, java.util.Map)
protected void retrievePropertiesOnResults(AttributeQueryResult queryResult, Collection<?> results, Suggest fieldSuggest)
queryResult
- the queryResult to fill inresults
- the set of original resultsfieldSuggest
- the Suggest widgetpublic AttributeQueryResult performFieldQuery(View view, String fieldId, Map<String,String> queryParameters)
AttributeQueryService
AttributeQuery
associated with the field given by the id. The given Map of key/value
pairs are used to populate the criteria part of the attribute query or as arguments to the query method.
The query is expected to return a Map of field name/value pairs (unlike the suggest query which just returns
values for one field)
performFieldQuery
in interface AttributeQueryService
view
- - view instance for which the field belongsfieldId
- - id for the attribute field to perform the query forqueryParameters
- - map of key/value pairs that are parameters to the query
org.kuali.rice.krad.uif.service.AttributeQueryService#performFieldQuery(org.kuali.rice.krad.uif.view.View,
java.lang.String, java.util.Map)
protected Object executeAttributeQueryMethod(View view, AttributeQuery attributeQuery, Map<String,String> queryParameters, boolean isSuggestQuery, String queryTerm)
view
- view instance the field is contained withinattributeQuery
- attribute query instance to executequeryParameters
- map of query parameters that provide values for the method argumentsisSuggestQuery
- indicates whether the query is for forming suggest optionsqueryTerm
- if being called for a suggest, the term for the query field
protected Collection<?> executeAttributeQueryCriteria(AttributeQuery attributeQuery, Map<String,String> queryParameters, Map<String,String> additionalCriteria)
attributeQuery
- attribute query instance to perform query forqueryParameters
- map of parameters that will be used in the query criteriaadditionalCriteria
- map of additional name/value pairs to add to the critiera
protected LookupService getLookupService()
public void setLookupService(LookupService lookupService)
lookupService
- protected ConfigurationService getConfigurationService()
public void setConfigurationService(ConfigurationService configurationService)
configurationService
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |