com.konakart.appif
Interface ProductSearchIf

All Known Implementing Classes:
ProductSearch

public interface ProductSearchIf

Contains information used to search the catalog for a product. Whenever an attribute is set, it is used as a constraint. When using the java API, a com.konakart.app.ProductSearch object is normally instantiated. Note that when this object initializes it sets the following attributes:

When using the SOAP interface without using the SOAP engine, this initialisation will not be done (because you will most probably be initializing an object created by a tool such as Apache Axis by reading the WSDL), so you will have to do it manually.


Method Summary
 int getCategoryId()
          Used as a constraint when not set to ProductSearch.SEARCH_ALL and when categoryIds is null or empty.
 int[] getCategoryIds()
          When not null and containing data, the category ids in this array are used to provide constraints and the categoryId attribute is ignored.
 java.util.Calendar getDateAddedFrom()
           
 java.util.Calendar getDateAddedTo()
           
 java.util.Calendar getDateAvailableFrom()
          The date available used for the search is that for the main product and not for the product variations.
 java.util.Calendar getDateAvailableTo()
          The date available used for the search is that for the main product and not for the product variations.
 java.util.Calendar getEndDateFrom()
          Used for Bookable Products
 java.util.Calendar getEndDateTo()
          Used for Bookable Products
 java.util.Calendar getExpiryDateFrom()
          Used to search for products based on the expiry date
 java.util.Calendar getExpiryDateTo()
          Used to search for products based on the expiry date
 int getManufacturerId()
          Used as a constraint when not set to ProductSearch.SEARCH_ALL and when manufacturerIds is null or empty.
 int[] getManufacturerIds()
          When not null and containing data, the manufacturer ids in this array are used to provide constraints and the manufacturerId attribute is ignored.
 java.lang.Integer getOrderedEqual()
          Returns all products that have been ordered a number of times equal to the value.
 java.lang.Integer getOrderedGreaterThan()
          Returns all products that have been ordered more times than the value.
 java.lang.Integer getOrderedLessThan()
          Returns all products that have been ordered less times than the value.
 java.util.Calendar getOverlapEndDate()
          When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object.
 java.util.Calendar getOverlapStartDate()
          When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object.
 java.math.BigDecimal getPriceFrom()
           
 java.math.BigDecimal getPriceTo()
           
 int getProductType()
           
 java.lang.Integer getQuantityEqual()
          Returns all products with a quantity equal to the value.
 java.lang.Integer getQuantityGreaterThan()
          Returns all products with a quantity greater than the value.
 java.lang.Integer getQuantityLessThan()
          Returns all products with a quantity less than the value.
 java.math.BigDecimal getRatingEqual()
          Returns all products with a rating equal to the value.
 java.math.BigDecimal getRatingGreaterThan()
          Returns all products with a rating greater than the value.
 java.math.BigDecimal getRatingLessThan()
          Returns all products with a rating less than the value.
 java.lang.String getSearchText()
           
 int getSearchTextRule()
          The rule for the search.
 SnippetOptionsIf getSnippetOptions()
          Used to configure fragments of text returned by the search engine that surround the keywords.
 java.util.Calendar getStartDateFrom()
          Used for Bookable Products
 java.util.Calendar getStartDateTo()
          Used for Bookable Products
 java.lang.String[] getStoresToSearch()
           
 TagGroupIf[] getTagGroups()
          For a single tag group, all products are returned that have any one of the tags in the group (i.e.
 int getWhereToSearch()
          When set to 0, the text search is done only on the product name.
 boolean isFillDescription()
          Fills the product description attribute with the description in the chosen language.
 boolean isReturnCategoryFacets()
          When set, the result of a product search using SOLR contains the category facets including the number of products per category.
 boolean isReturnCustomFacets()
          When set, the result of a product search using SOLR contains the custom facets.
 boolean isReturnManufacturerFacets()
          When set, the result of a product search using SOLR contains the manufacturer facets including the number of products per manufacturer.
 boolean isSearchAllStores()
           
 boolean isSearchInSubCats()
          Determines whether products are searched for in child categories when there are category constraints.
 void setCategoryId(int categoryId)
          Used as a constraint when not set to ProductSearch.SEARCH_ALL and when categoryIds is null or empty.
 void setCategoryIds(int[] categoryIds)
          When not null and containing data, the category ids in this array are used to provide constraints and the categoryId attribute is ignored.
 void setDateAddedFrom(java.util.Calendar dateAddedFrom)
           
 void setDateAddedTo(java.util.Calendar dateAddedTo)
           
 void setDateAvailableFrom(java.util.Calendar dateAvailableFrom)
          The date available used for the search is that for the main product and not for the product variations.
 void setDateAvailableTo(java.util.Calendar dateAvailableTo)
          The date available used for the search is that for the main product and not for the product variations.
 void setEndDateFrom(java.util.Calendar endDateFrom)
          Used for Bookable Products
 void setEndDateTo(java.util.Calendar endDateTo)
          Used for Bookable Products
 void setExpiryDateFrom(java.util.Calendar expiryDateFrom)
          Used to search for products based on the expiry date
 void setExpiryDateTo(java.util.Calendar expiryDateTo)
          Used to search for products based on the expiry date
 void setFillDescription(boolean fillDescription)
          Fills the product description attribute with the description in the chosen language.
 void setManufacturerId(int manufacturerId)
          Used as a constraint when not set to ProductSearch.SEARCH_ALL and when manufacturerIds is null or empty.
 void setManufacturerIds(int[] manufacturerIds)
          When not null and containing data, the manufacturer ids in this array are used to provide constraints and the manufacturerId attribute is ignored.
 void setOrderedEqual(java.lang.Integer orderedEqual)
          Returns all products that have been ordered a number of times equal to the value.
 void setOrderedGreaterThan(java.lang.Integer orderedGreaterThan)
          Returns all products that have been ordered more times than the value.
 void setOrderedLessThan(java.lang.Integer orderedLessThan)
          Returns all products that have been ordered less times than the value.
 void setOverlapEndDate(java.util.Calendar overlapEndDate)
          When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object.
 void setOverlapStartDate(java.util.Calendar overlapStartDate)
          When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object.
 void setPriceFrom(java.math.BigDecimal priceFrom)
           
 void setPriceTo(java.math.BigDecimal priceTo)
           
 void setProductType(int productType)
          Set this to search for products with a specific product type.
 void setQuantityEqual(java.lang.Integer quantityEqual)
          Returns all products with a quantity equal to the value.
 void setQuantityGreaterThan(java.lang.Integer quantityGreaterThan)
          Returns all products with a quantity greater than the value.
 void setQuantityLessThan(java.lang.Integer quantityLessThan)
          Returns all products with a quantity less than the value.
 void setRatingEqual(java.math.BigDecimal ratingEqual)
          Returns all products with a rating equal to the value.
 void setRatingGreaterThan(java.math.BigDecimal ratingGreaterThan)
          Returns all products with a rating greater than the value.
 void setRatingLessThan(java.math.BigDecimal ratingLessThan)
          Returns all products with a rating less than the value.
 void setReturnCategoryFacets(boolean returnCategoryFacets)
          When set, the result of a product search using SOLR contains the category facets including the number of products per category.
 void setReturnCustomFacets(boolean returnCustomFacets)
          When set, the result of a product search using SOLR contains the custom facets.
 void setReturnManufacturerFacets(boolean returnManufacturerFacets)
          When set, the result of a product search using SOLR contains the manufacturer facets including the number of products per manufacturer.
 void setSearchAllStores(boolean searchAllStores)
           
 void setSearchInSubCats(boolean searchInSubCats)
          Determines whether products are searched for in child categories when there are category constraints.
 void setSearchText(java.lang.String searchText)
           
 void setSearchTextRule(int searchTextRule)
          The rule for the search.
 void setSnippetOptions(SnippetOptionsIf snippetOptions)
          Used to configure fragments of text returned by the search engine that surround the keywords.
 void setStartDateFrom(java.util.Calendar startDateFrom)
          Used for Bookable Products
 void setStartDateTo(java.util.Calendar startDateTo)
          Used for Bookable Products
 void setStoresToSearch(java.lang.String[] storesToSearch)
           
 void setTagGroups(TagGroupIf[] tagGroups)
          For a single tag group, all products are returned that have any one of the tags in the group (i.e.
 void setWhereToSearch(int whereToSearch)
          When set to 0, the text search is done only on the product name.
 

Method Detail

getCategoryId

int getCategoryId()
Used as a constraint when not set to ProductSearch.SEARCH_ALL and when categoryIds is null or empty. If the category is a parent category, it only applies to products directly under this category and not to products within child categories unless searchInSubCats is set to true.

Returns:
Returns the categoryId.

setCategoryId

void setCategoryId(int categoryId)
Used as a constraint when not set to ProductSearch.SEARCH_ALL and when categoryIds is null or empty. If the category is a parent category, it only applies to products directly under this category and not to products within child categories unless searchInSubCats is set to true.

Parameters:
categoryId - The categoryId to set.

getManufacturerId

int getManufacturerId()
Used as a constraint when not set to ProductSearch.SEARCH_ALL and when manufacturerIds is null or empty.

Returns:
Returns the manufacturerId.

setManufacturerId

void setManufacturerId(int manufacturerId)
Used as a constraint when not set to ProductSearch.SEARCH_ALL and when manufacturerIds is null or empty.

Parameters:
manufacturerId - The manufacturerId to set.

getPriceFrom

java.math.BigDecimal getPriceFrom()
Returns:
Returns the priceFrom.

setPriceFrom

void setPriceFrom(java.math.BigDecimal priceFrom)
Parameters:
priceFrom - The priceFrom to set.

getPriceTo

java.math.BigDecimal getPriceTo()
Returns:
Returns the priceTo.

setPriceTo

void setPriceTo(java.math.BigDecimal priceTo)
Parameters:
priceTo - The priceTo to set.

getSearchText

java.lang.String getSearchText()
Returns:
Returns the searchText.

setSearchText

void setSearchText(java.lang.String searchText)
Parameters:
searchText - The searchText to set.

getWhereToSearch

int getWhereToSearch()
When set to 0, the text search is done only on the product name. When set to com.konakart.app.ProductSearch.SEARCH_IN_PRODUCT_DESCRIPTION the search is done in the product description also.

Returns:
Returns the whereToSearch.

setWhereToSearch

void setWhereToSearch(int whereToSearch)
When set to 0, the text search is done only on the product name. When set to com.konakart.app.ProductSearch.SEARCH_IN_PRODUCT_DESCRIPTION the search is done in the product description also.

Parameters:
whereToSearch - The whereToSearch to set.

getDateAddedFrom

java.util.Calendar getDateAddedFrom()
Returns:
Returns the dateAddedFrom.

setDateAddedFrom

void setDateAddedFrom(java.util.Calendar dateAddedFrom)
Parameters:
dateAddedFrom - The dateAddedFrom to set.

getDateAddedTo

java.util.Calendar getDateAddedTo()
Returns:
Returns the dateAddedTo.

setDateAddedTo

void setDateAddedTo(java.util.Calendar dateAddedTo)
Parameters:
dateAddedTo - The dateAddedTo to set.

isSearchInSubCats

boolean isSearchInSubCats()
Determines whether products are searched for in child categories when there are category constraints.

Returns:
Returns the searchInSubCats.

setSearchInSubCats

void setSearchInSubCats(boolean searchInSubCats)
Determines whether products are searched for in child categories when there are category constraints.

Parameters:
searchInSubCats - The searchInSubCats to set.

getTagGroups

TagGroupIf[] getTagGroups()
For a single tag group, all products are returned that have any one of the tags in the group (i.e. All products that have tag1 OR tag2 OR tag3). If there is more than one tag group, then the only products returned are the ones that satisfy the filters of all the groups. i.e. In order to be returned, a product has to satisfy the filters of tag group1 AND tag group2 AND tag group3.

For example in the case of digital cameras, one tag group could contain tags for the number of megapixels and another group could contain tags for the battery type. Using the above logic it is straightforward to search for a camera that has a 4MPixel OR a 6MPixel sensor AND has a rechargeable battery.

Returns:
Returns the tagGroups.

setTagGroups

void setTagGroups(TagGroupIf[] tagGroups)
For a single tag group, all products are returned that have any one of the tags in the group (i.e. All products that have tag1 OR tag2 OR tag3). If there is more than one tag group, then the only products returned are the ones that satisfy the filters of all the groups. i.e. In order to be returned, a product has to satisfy the filters of tag group1 AND tag group2 AND tag group3.

For example in the case of digital cameras, one tag group could contain tags for the number of megapixels and another group could contain tags for the battery type. Using the above logic it is straightforward to search for a camera that has a 4MPixel OR a 6MPixel sensor AND has a rechargeable battery.

Parameters:
tagGroups - The tagGroups to set.

isSearchAllStores

boolean isSearchAllStores()
Returns:
Returns boolean

setSearchAllStores

void setSearchAllStores(boolean searchAllStores)
Parameters:
searchAllStores -

getStoresToSearch

java.lang.String[] getStoresToSearch()
Returns:
Returns an array of store ids

setStoresToSearch

void setStoresToSearch(java.lang.String[] storesToSearch)
Parameters:
storesToSearch -

getSnippetOptions

SnippetOptionsIf getSnippetOptions()
Used to configure fragments of text returned by the search engine that surround the keywords. Can be set to null.

Returns:
the snippetOptions

setSnippetOptions

void setSnippetOptions(SnippetOptionsIf snippetOptions)
Used to configure fragments of text returned by the search engine that surround the keywords. Can be set to null.

Parameters:
snippetOptions - the snippetOptions to set

getRatingGreaterThan

java.math.BigDecimal getRatingGreaterThan()
Returns all products with a rating greater than the value.

Returns:
the ratingGreaterThan

setRatingGreaterThan

void setRatingGreaterThan(java.math.BigDecimal ratingGreaterThan)
Returns all products with a rating greater than the value.

Parameters:
ratingGreaterThan - the ratingGreaterThan to set

getRatingLessThan

java.math.BigDecimal getRatingLessThan()
Returns all products with a rating less than the value.

Returns:
the ratingLessThan

setRatingLessThan

void setRatingLessThan(java.math.BigDecimal ratingLessThan)
Returns all products with a rating less than the value.

Parameters:
ratingLessThan - the ratingLessThan to set

getRatingEqual

java.math.BigDecimal getRatingEqual()
Returns all products with a rating equal to the value.

Returns:
the ratingEqual

setRatingEqual

void setRatingEqual(java.math.BigDecimal ratingEqual)
Returns all products with a rating equal to the value.

Parameters:
ratingEqual - the ratingEqual to set

getDateAvailableTo

java.util.Calendar getDateAvailableTo()
The date available used for the search is that for the main product and not for the product variations.

Returns:
the dateAvailableTo

setDateAvailableTo

void setDateAvailableTo(java.util.Calendar dateAvailableTo)
The date available used for the search is that for the main product and not for the product variations.

Parameters:
dateAvailableTo - the dateAvailableTo to set

getDateAvailableFrom

java.util.Calendar getDateAvailableFrom()
The date available used for the search is that for the main product and not for the product variations.

Returns:
the dateAvailableFrom

setDateAvailableFrom

void setDateAvailableFrom(java.util.Calendar dateAvailableFrom)
The date available used for the search is that for the main product and not for the product variations.

Parameters:
dateAvailableFrom - the dateAvailableFrom to set

getExpiryDateTo

java.util.Calendar getExpiryDateTo()
Used to search for products based on the expiry date

Returns:
the expiryDateTo

setExpiryDateTo

void setExpiryDateTo(java.util.Calendar expiryDateTo)
Used to search for products based on the expiry date

Parameters:
expiryDateTo - the expiryDateTo to set

getExpiryDateFrom

java.util.Calendar getExpiryDateFrom()
Used to search for products based on the expiry date

Returns:
the expiryDateFrom

setExpiryDateFrom

void setExpiryDateFrom(java.util.Calendar expiryDateFrom)
Used to search for products based on the expiry date

Parameters:
expiryDateFrom - the expiryDateFrom to set

isFillDescription

boolean isFillDescription()
Fills the product description attribute with the description in the chosen language. Normally this is not returned for performance reasons.

Returns:
the fillDescription

setFillDescription

void setFillDescription(boolean fillDescription)
Fills the product description attribute with the description in the chosen language. Normally this is not returned for performance reasons.

Parameters:
fillDescription - the fillDescription to set

getSearchTextRule

int getSearchTextRule()
The rule for the search. Valid values are:

Returns:
the searchTextRule

setSearchTextRule

void setSearchTextRule(int searchTextRule)
The rule for the search. Valid values are:

Parameters:
searchTextRule - the searchTextRule to set

getQuantityGreaterThan

java.lang.Integer getQuantityGreaterThan()
Returns all products with a quantity greater than the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Returns:
the quantityGreaterThan

setQuantityGreaterThan

void setQuantityGreaterThan(java.lang.Integer quantityGreaterThan)
Returns all products with a quantity greater than the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Parameters:
quantityGreaterThan - the quantityGreaterThan to set

getQuantityLessThan

java.lang.Integer getQuantityLessThan()
Returns all products with a quantity less than the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Returns:
the quantityLessThan

setQuantityLessThan

void setQuantityLessThan(java.lang.Integer quantityLessThan)
Returns all products with a quantity less than the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Parameters:
quantityLessThan - the quantityLessThan to set

getQuantityEqual

java.lang.Integer getQuantityEqual()
Returns all products with a quantity equal to the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Returns:
the quantityEqual

setQuantityEqual

void setQuantityEqual(java.lang.Integer quantityEqual)
Returns all products with a quantity equal to the value. Note that it uses the quantity attribute of the product object and doesn't use the quantities of product variations.

Parameters:
quantityEqual - the quantityEqual to set

getStartDateFrom

java.util.Calendar getStartDateFrom()
Used for Bookable Products

Returns:
the startDateFrom

setStartDateFrom

void setStartDateFrom(java.util.Calendar startDateFrom)
Used for Bookable Products

Parameters:
startDateFrom - the startDateFrom to set

getStartDateTo

java.util.Calendar getStartDateTo()
Used for Bookable Products

Returns:
the startDateTo

setStartDateTo

void setStartDateTo(java.util.Calendar startDateTo)
Used for Bookable Products

Parameters:
startDateTo - the startDateTo to set

getEndDateFrom

java.util.Calendar getEndDateFrom()
Used for Bookable Products

Returns:
the endDateFrom

setEndDateFrom

void setEndDateFrom(java.util.Calendar endDateFrom)
Used for Bookable Products

Parameters:
endDateFrom - the endDateFrom to set

getEndDateTo

java.util.Calendar getEndDateTo()
Used for Bookable Products

Returns:
the endDateTo

setEndDateTo

void setEndDateTo(java.util.Calendar endDateTo)
Used for Bookable Products

Parameters:
endDateTo - the endDateTo to set

getOverlapStartDate

java.util.Calendar getOverlapStartDate()
When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object. This search does not use the SOLR search engine.

Returns:
the overlapStartDate

setOverlapStartDate

void setOverlapStartDate(java.util.Calendar overlapStartDate)
When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object. This search does not use the SOLR search engine.

Parameters:
overlapStartDate - the overlapStartDate to set

getOverlapEndDate

java.util.Calendar getOverlapEndDate()
When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object. This search does not use the SOLR search engine.

Returns:
the overlapEndDate

setOverlapEndDate

void setOverlapEndDate(java.util.Calendar overlapEndDate)
When overlapStart and end dates are both set, a search is done for all products that have start and end dates that make them overlap the dates set in this search object. This search does not use the SOLR search engine.

Parameters:
overlapEndDate - the overlapEndDate to set

getProductType

int getProductType()
Returns:
the productType

setProductType

void setProductType(int productType)
Set this to search for products with a specific product type. This is only used if the value is greater than or equal to 0.

Parameters:
productType - the productType to set

isReturnManufacturerFacets

boolean isReturnManufacturerFacets()
When set, the result of a product search using SOLR contains the manufacturer facets including the number of products per manufacturer.

Returns:
the returnManufacturerFacets

setReturnManufacturerFacets

void setReturnManufacturerFacets(boolean returnManufacturerFacets)
When set, the result of a product search using SOLR contains the manufacturer facets including the number of products per manufacturer.

Parameters:
returnManufacturerFacets - the returnManufacturerFacets to set

isReturnCategoryFacets

boolean isReturnCategoryFacets()
When set, the result of a product search using SOLR contains the category facets including the number of products per category.

Returns:
the returnCategoryFacets

setReturnCategoryFacets

void setReturnCategoryFacets(boolean returnCategoryFacets)
When set, the result of a product search using SOLR contains the category facets including the number of products per category.

Parameters:
returnCategoryFacets - the returnCategoryFacets to set

getManufacturerIds

int[] getManufacturerIds()
When not null and containing data, the manufacturer ids in this array are used to provide constraints and the manufacturerId attribute is ignored.

Returns:
the manufacturerIds

setManufacturerIds

void setManufacturerIds(int[] manufacturerIds)
When not null and containing data, the manufacturer ids in this array are used to provide constraints and the manufacturerId attribute is ignored.

Parameters:
manufacturerIds - the manufacturerIds to set

getCategoryIds

int[] getCategoryIds()
When not null and containing data, the category ids in this array are used to provide constraints and the categoryId attribute is ignored.

Returns:
the categoryIds

setCategoryIds

void setCategoryIds(int[] categoryIds)
When not null and containing data, the category ids in this array are used to provide constraints and the categoryId attribute is ignored.

Parameters:
categoryIds - the categoryIds to set

getOrderedGreaterThan

java.lang.Integer getOrderedGreaterThan()
Returns all products that have been ordered more times than the value. Note that it uses the ordered attribute of the product object.

Returns:
the orderedGreaterThan

setOrderedGreaterThan

void setOrderedGreaterThan(java.lang.Integer orderedGreaterThan)
Returns all products that have been ordered more times than the value. Note that it uses the ordered attribute of the product object.

Parameters:
orderedGreaterThan - the orderedGreaterThan to set

getOrderedLessThan

java.lang.Integer getOrderedLessThan()
Returns all products that have been ordered less times than the value. Note that it uses the ordered attribute of the product object.

Returns:
the orderedLessThan

setOrderedLessThan

void setOrderedLessThan(java.lang.Integer orderedLessThan)
Returns all products that have been ordered less times than the value. Note that it uses the ordered attribute of the product object.

Parameters:
orderedLessThan - the orderedLessThan to set

getOrderedEqual

java.lang.Integer getOrderedEqual()
Returns all products that have been ordered a number of times equal to the value. Note that it uses the ordered attribute of the product object.

Returns:
the orderedEqual

setOrderedEqual

void setOrderedEqual(java.lang.Integer orderedEqual)
Returns all products that have been ordered a number of times equal to the value. Note that it uses the ordered attribute of the product object.

Parameters:
orderedEqual - the orderedEqual to set

isReturnCustomFacets

boolean isReturnCustomFacets()
When set, the result of a product search using SOLR contains the custom facets.

Returns:
the returnCustomFacets

setReturnCustomFacets

void setReturnCustomFacets(boolean returnCustomFacets)
When set, the result of a product search using SOLR contains the custom facets.

Parameters:
returnCustomFacets - the returnCustomFacets to set


Copyright © 2011 DS Data Systems UK Ltd.