Package io.jmix.search.searching
Class SearchRequestScopeProvider
java.lang.Object
io.jmix.search.searching.SearchRequestScopeProvider
@Component("search_SearchRequestScopeProvider")
public class SearchRequestScopeProvider
extends Object
This class contains methods for getting information for the search request building.
The analysis is based on the
IndexConfiguration objects and entities metadata processing.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final IndexConfigurationManagerprotected final SearchFieldsProviderprotected final SearchSecurityDecorator -
Constructor Summary
ConstructorsConstructorDescriptionSearchRequestScopeProvider(SearchSecurityDecorator securityDecorator, IndexConfigurationManager indexConfigurationManager, SearchFieldsProvider searchFieldsProvider) -
Method Summary
Modifier and TypeMethodDescriptionprotected Collection<String>getEntitiesWithConfiguration(List<String> entities) getSearchRequestScope(List<String> entities, VirtualSubfieldsProvider virtualSubfieldsProvider) TODO Pavel Aleksandrov rewrite Calculates a map for the search request building.
-
Field Details
-
securityDecorator
-
indexConfigurationManager
-
searchFieldsProvider
-
-
Constructor Details
-
SearchRequestScopeProvider
public SearchRequestScopeProvider(SearchSecurityDecorator securityDecorator, IndexConfigurationManager indexConfigurationManager, SearchFieldsProvider searchFieldsProvider)
-
-
Method Details
-
getSearchRequestScope
public List<IndexSearchRequestScope> getSearchRequestScope(List<String> entities, VirtualSubfieldsProvider virtualSubfieldsProvider) TODO Pavel Aleksandrov rewrite Calculates a map for the search request building. The method takes into account user rights to entities and their parameters. The method adds additional subfields name of which can be provided with the subfieldsProvider parameter.- Parameters:
entities- - a collection of the entity names for the search request buildingvirtualSubfieldsProvider- aFunctionfor getting subfields of the index field. If the function returns an empty set, the only initial field name will be added to the result.- Returns:
- a map that contains indexNames as keys and sets of corresponding fieldNames as values
from the correspondent
IndexMappingConfigurationfor each index.
-
getEntitiesWithConfiguration
-