Interface SearchManagerService
-
- All Known Implementing Classes:
SearchManagerServiceImpl
public interface SearchManagerService
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
aiSearchIsActive()
Checks if the AI search functionality is currently active.java.util.List<java.lang.String>
aiSearchKeywords(java.lang.String query)
Searches for keywords related to the provided query using AI.java.lang.String
applyFilters(co.mastermindcms.modules.beans.SearchRequest request)
Applies filters to a search request and returns a filtered query definition.long
countAll(co.mastermindcms.modules.beans.SearchRequest request)
Counts the total number of items that match the given search request.long
countAll(java.util.LinkedHashMap<java.lang.String,java.lang.Object> request)
Counts the total number of items that match the given search request.java.lang.String[]
doProcessSearchTerms(java.lang.String searchTerms)
Processes the provided search terms by performing a specific action.java.util.List<co.mastermindcms.modules.beans.GroupFilter>
fieldFilterValues(java.lang.String filterId, java.lang.String type)
Retrieves a list of group filters based on the provided filter ID.java.util.List<co.mastermindcms.modules.beans.GroupFilter>
listFilters()
This method collects all the list filtersjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
listFilterValues(java.lang.String filterId)
This method collects all values from filterco.mastermindcms.modules.beans.GroupFilter
listingFeatureFromAttribute(java.lang.String filterId, java.lang.String sellerSkuId)
This method retrieves a feature for specific listingjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
logicalFilters()
This method collects all the boolean filtersjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
numericFilters()
This method collects all the numeric filtersjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
numericFilterValues(java.lang.String filterId)
This method collects all values from filterjava.util.List<java.lang.String>
parseSearchQuery(java.lang.String query)
Parses the search query to extract individual search terms.static org.springframework.data.mongodb.core.aggregation.MatchOperation
published()
This is helper method which is provided prepared match criteria for aggregationjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
rangeFilters()
This method collects all the range filtersjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
rangeFilterValues(java.lang.String filterId)
This method collects all values from filterco.mastermindcms.modules.beans.SearchResponse
search(co.mastermindcms.modules.beans.SearchRequest request)
This method does search requests and returns data as pages.co.mastermindcms.modules.beans.SearchResponse
search(java.util.LinkedHashMap<java.lang.String,java.lang.Object> request)
This method does search requests and returns data as pages.java.util.List<co.mastermindcms.modules.beans.GroupFilter>
simpleFilters()
This method collects all the simple filtersjava.util.List<co.mastermindcms.modules.beans.GroupFilter>
simpleFilterValues(java.lang.String filterId)
This method collects all values from filter
-
-
-
Method Detail
-
search
co.mastermindcms.modules.beans.SearchResponse search(java.util.LinkedHashMap<java.lang.String,java.lang.Object> request)
This method does search requests and returns data as pages.- Parameters:
request
- search request as map- Returns:
- database entities separated to pages
-
search
co.mastermindcms.modules.beans.SearchResponse search(co.mastermindcms.modules.beans.SearchRequest request)
This method does search requests and returns data as pages.- Parameters:
request
- search request as entity- Returns:
- database entities separated to pages
-
countAll
long countAll(java.util.LinkedHashMap<java.lang.String,java.lang.Object> request)
Counts the total number of items that match the given search request.- Parameters:
request
- search request as map- Returns:
- the total number of items that match the search request
-
countAll
long countAll(co.mastermindcms.modules.beans.SearchRequest request)
Counts the total number of items that match the given search request.- Parameters:
request
- the search request containing the criteria for the search- Returns:
- the total number of items that match the search request
-
logicalFilters
java.util.List<co.mastermindcms.modules.beans.GroupFilter> logicalFilters()
This method collects all the boolean filters- Returns:
- the collection of all logical filters
-
rangeFilters
java.util.List<co.mastermindcms.modules.beans.GroupFilter> rangeFilters()
This method collects all the range filters- Returns:
- the collection of all range filters
-
simpleFilters
java.util.List<co.mastermindcms.modules.beans.GroupFilter> simpleFilters()
This method collects all the simple filters- Returns:
- the collection of all simple filters
-
numericFilters
java.util.List<co.mastermindcms.modules.beans.GroupFilter> numericFilters()
This method collects all the numeric filters- Returns:
- the collection of all numeric filters
-
listFilters
java.util.List<co.mastermindcms.modules.beans.GroupFilter> listFilters()
This method collects all the list filters- Returns:
- the collection of all list filters
-
rangeFilterValues
java.util.List<co.mastermindcms.modules.beans.GroupFilter> rangeFilterValues(java.lang.String filterId)
This method collects all values from filter- Parameters:
filterId
- filter object identifier- Returns:
- the list of all filter values
-
listFilterValues
java.util.List<co.mastermindcms.modules.beans.GroupFilter> listFilterValues(java.lang.String filterId)
This method collects all values from filter- Parameters:
filterId
- filter object identifier- Returns:
- the list of all filter values
-
simpleFilterValues
java.util.List<co.mastermindcms.modules.beans.GroupFilter> simpleFilterValues(java.lang.String filterId)
This method collects all values from filter- Parameters:
filterId
- filter object identifier- Returns:
- the list of all filter values
-
numericFilterValues
java.util.List<co.mastermindcms.modules.beans.GroupFilter> numericFilterValues(java.lang.String filterId)
This method collects all values from filter- Parameters:
filterId
- filter object identifier- Returns:
- the list of all filter values
-
fieldFilterValues
java.util.List<co.mastermindcms.modules.beans.GroupFilter> fieldFilterValues(java.lang.String filterId, java.lang.String type)
Retrieves a list of group filters based on the provided filter ID.- Parameters:
filterId
- the ID of the filter to retrieve values fortype
- type of the entity- Returns:
- a list of GroupFilter objects containing the filter values
-
listingFeatureFromAttribute
co.mastermindcms.modules.beans.GroupFilter listingFeatureFromAttribute(java.lang.String filterId, java.lang.String sellerSkuId)
This method retrieves a feature for specific listing- Parameters:
filterId
- filter identifiersellerSkuId
- listing identifier- Returns:
- the value of listing feature
-
published
static org.springframework.data.mongodb.core.aggregation.MatchOperation published()
This is helper method which is provided prepared match criteria for aggregation- Returns:
- criteria for published listing
-
applyFilters
java.lang.String applyFilters(co.mastermindcms.modules.beans.SearchRequest request)
Applies filters to a search request and returns a filtered query definition.- Parameters:
request
- the search request containing filter options- Returns:
- a filtered query definition
-
doProcessSearchTerms
java.lang.String[] doProcessSearchTerms(java.lang.String searchTerms)
Processes the provided search terms by performing a specific action.- Parameters:
searchTerms
- An array of search terms to be processed- Returns:
- A modified array of search terms after processing
-
aiSearchKeywords
java.util.List<java.lang.String> aiSearchKeywords(java.lang.String query)
Searches for keywords related to the provided query using AI.- Parameters:
query
- The search query for which keywords are to be searched- Returns:
- A list of keywords related to the query
-
aiSearchIsActive
boolean aiSearchIsActive()
Checks if the AI search functionality is currently active.- Returns:
- True if AI search is active, false otherwise
-
parseSearchQuery
java.util.List<java.lang.String> parseSearchQuery(java.lang.String query)
Parses the search query to extract individual search terms.- Parameters:
query
- The search query to be parsed- Returns:
- A list of individual search terms extracted from the query
-
-