|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.broadleafcommerce.core.search.service.DatabaseSearchServiceImpl
@Service(value="blSearchService") public class DatabaseSearchServiceImpl
| Field Summary | |
|---|---|
protected net.sf.ehcache.Cache |
cache
|
protected static String |
CACHE_KEY_PREFIX
|
protected static String |
CACHE_NAME
|
protected CatalogService |
catalogService
|
protected FieldDao |
fieldDao
|
protected SearchFacetDao |
searchFacetDao
|
| Constructor Summary | |
|---|---|
DatabaseSearchServiceImpl()
|
|
| Method Summary | |
|---|---|
protected List<SearchFacetDTO> |
buildSearchFacetDtos(List<SearchFacet> categoryFacets)
Create the wrapper DTO around the SearchFacet |
ProductSearchResult |
findExplicitProductsByCategory(Category category,
ProductSearchCriteria searchCriteria)
Performs a search for products in the given category, taking into consideration the ProductSearchCriteria This method will NOT return products that are in a sub-level of a given category. |
ProductSearchResult |
findProductsByCategory(Category category,
ProductSearchCriteria searchCriteria)
Performs a search for products in the given category, taking into consideration the ProductSearchCriteria This method will return products that are in any sub-level of a given category. |
ProductSearchResult |
findProductsByCategoryAndQuery(Category category,
String query,
ProductSearchCriteria searchCriteria)
Performs a search for products in the given category for the given query, taking into consideration the ProductSearchCriteria |
ProductSearchResult |
findProductsByQuery(String query,
ProductSearchCriteria searchCriteria)
Performs a search for products across all categories for the given query, taking into consideration the ProductSearchCriteria |
List<SearchFacetDTO> |
getCategoryFacets(Category category)
Gets all available facets for a given category |
protected String |
getDatabaseQualifiedFieldName(String qualifiedFieldName)
From the Field's qualifiedName, build out the qualified name to be used by the ProductDao to find the requested products. |
protected List<SearchFacetResultDTO> |
getFacetValues(SearchFacet facet)
|
protected List<SearchFacetResultDTO> |
getMatchFacetValues(SearchFacet facet)
|
protected List<SearchFacetResultDTO> |
getRangeFacetValues(SearchFacet facet)
|
List<SearchFacetDTO> |
getSearchFacets()
Gets all available facets for search results page |
void |
rebuildIndex()
Rebuilds the current index. |
protected void |
setActiveFacets(List<SearchFacetDTO> facets,
ProductSearchCriteria searchCriteria)
|
protected void |
setQualifiedKeys(ProductSearchCriteria criteria)
Perform any necessary conversion of the key to be used by the search service |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected CatalogService catalogService
protected SearchFacetDao searchFacetDao
protected FieldDao fieldDao
protected static String CACHE_NAME
protected static String CACHE_KEY_PREFIX
protected net.sf.ehcache.Cache cache
| Constructor Detail |
|---|
public DatabaseSearchServiceImpl()
| Method Detail |
|---|
public ProductSearchResult findExplicitProductsByCategory(Category category,
ProductSearchCriteria searchCriteria)
throws ServiceException
SearchService
findExplicitProductsByCategory in interface SearchServiceServiceExceptionSearchService.findProductsByCategory(Category, ProductSearchCriteria)
public ProductSearchResult findProductsByCategoryAndQuery(Category category,
String query,
ProductSearchCriteria searchCriteria)
throws ServiceException
SearchService
findProductsByCategoryAndQuery in interface SearchServiceServiceException
public ProductSearchResult findProductsByCategory(Category category,
ProductSearchCriteria searchCriteria)
SearchService
findProductsByCategory in interface SearchServiceSearchService.findExplicitProductsByCategory(Category, ProductSearchCriteria)
public ProductSearchResult findProductsByQuery(String query,
ProductSearchCriteria searchCriteria)
SearchService
findProductsByQuery in interface SearchServicepublic List<SearchFacetDTO> getSearchFacets()
SearchService
getSearchFacets in interface SearchServicepublic List<SearchFacetDTO> getCategoryFacets(Category category)
SearchService
getCategoryFacets in interface SearchServiceprotected void setQualifiedKeys(ProductSearchCriteria criteria)
criteria - protected String getDatabaseQualifiedFieldName(String qualifiedFieldName)
qualifiedFieldName -
protected void setActiveFacets(List<SearchFacetDTO> facets,
ProductSearchCriteria searchCriteria)
protected List<SearchFacetDTO> buildSearchFacetDtos(List<SearchFacet> categoryFacets)
categoryFacets -
protected List<SearchFacetResultDTO> getFacetValues(SearchFacet facet)
protected List<SearchFacetResultDTO> getRangeFacetValues(SearchFacet facet)
protected List<SearchFacetResultDTO> getMatchFacetValues(SearchFacet facet)
public void rebuildIndex()
SearchService
rebuildIndex in interface SearchService
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||