Class BaseSearchParamsWithoutQuery

java.lang.Object
com.algolia.model.search.BaseSearchParamsWithoutQuery

public class BaseSearchParamsWithoutQuery extends Object
BaseSearchParamsWithoutQuery
  • Constructor Details

    • BaseSearchParamsWithoutQuery

      public BaseSearchParamsWithoutQuery()
  • Method Details

    • setSimilarQuery

      public BaseSearchParamsWithoutQuery setSimilarQuery(String similarQuery)
    • getSimilarQuery

      @Nullable public String getSimilarQuery()
      Keywords to be used instead of the search query to conduct a more broader search. Using the `similarQuery` parameter changes other settings: - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords`. Since the `similarQuery` is supposed to do a broad search, they usually return many results. Combine it with `filters` to narrow down the list of results.
    • setFilters

      public BaseSearchParamsWithoutQuery setFilters(String filters)
    • getFilters

      @Nullable public String getFilters()
      Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** ` `, where `` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `: TO ` where `` and `` are the lower and upper limits of the range (inclusive). - **Facet filters.** `:` where `` is a facet attribute (case-sensitive) and `` a facet value. - **Tag filters.** `_tags:` or just `` (case-sensitive). - **Boolean filters.** `: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can't use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can't combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes around your filters, if the facet attribute name or facet value has spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/).
    • setFacetFilters

      public BaseSearchParamsWithoutQuery setFacetFilters(FacetFilters facetFilters)
    • getFacetFilters

      @Nullable public FacetFilters getFacetFilters()
      Get facetFilters
    • setOptionalFilters

      public BaseSearchParamsWithoutQuery setOptionalFilters(OptionalFilters optionalFilters)
    • getOptionalFilters

      @Nullable public OptionalFilters getOptionalFilters()
      Get optionalFilters
    • setNumericFilters

      public BaseSearchParamsWithoutQuery setNumericFilters(NumericFilters numericFilters)
    • getNumericFilters

      @Nullable public NumericFilters getNumericFilters()
      Get numericFilters
    • setTagFilters

      public BaseSearchParamsWithoutQuery setTagFilters(TagFilters tagFilters)
    • getTagFilters

      @Nullable public TagFilters getTagFilters()
      Get tagFilters
    • setSumOrFiltersScores

      public BaseSearchParamsWithoutQuery setSumOrFiltersScores(Boolean sumOrFiltersScores)
    • getSumOrFiltersScores

      @Nullable public Boolean getSumOrFiltersScores()
      Whether to sum all filter scores. If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).
    • setRestrictSearchableAttributes

      public BaseSearchParamsWithoutQuery setRestrictSearchableAttributes(List<String> restrictSearchableAttributes)
    • addRestrictSearchableAttributes

      public BaseSearchParamsWithoutQuery addRestrictSearchableAttributes(String restrictSearchableAttributesItem)
    • getRestrictSearchableAttributes

      @Nullable public List<String> getRestrictSearchableAttributes()
      Restricts a search to a subset of your searchable attributes. Attribute names are case-sensitive.
    • setFacets

      public BaseSearchParamsWithoutQuery setFacets(List<String> facets)
    • addFacets

      public BaseSearchParamsWithoutQuery addFacets(String facetsItem)
    • getFacets

      @Nullable public List<String> getFacets()
      Facets for which to retrieve facet values that match the search criteria and the number of matching facet values. To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
    • setFacetingAfterDistinct

      public BaseSearchParamsWithoutQuery setFacetingAfterDistinct(Boolean facetingAfterDistinct)
    • getFacetingAfterDistinct

      @Nullable public Boolean getFacetingAfterDistinct()
      Whether faceting should be applied after deduplication with `distinct`. This leads to accurate facet counts when using faceting in combination with `distinct`. It's usually better to use `afterDistinct` modifiers in the `attributesForFaceting` setting, as `facetingAfterDistinct` only computes correct facet counts if all records have the same facet values for the `attributeForDistinct`.
    • setPage

      public BaseSearchParamsWithoutQuery setPage(Integer page)
    • getPage

      @Nullable public Integer getPage()
      Page of search results to retrieve. minimum: 0
    • setOffset

      public BaseSearchParamsWithoutQuery setOffset(Integer offset)
    • getOffset

      @Nullable public Integer getOffset()
      Position of the first hit to retrieve.
    • setLength

      public BaseSearchParamsWithoutQuery setLength(Integer length)
    • getLength

      @Nullable public Integer getLength()
      Number of hits to retrieve (used in combination with `offset`). minimum: 1 maximum: 1000
    • setAroundLatLng

      public BaseSearchParamsWithoutQuery setAroundLatLng(String aroundLatLng)
    • getAroundLatLng

      @Nullable public String getAroundLatLng()
      Coordinates for the center of a circle, expressed as a comma-separated string of latitude and longitude. Only records included within circle around this central location are included in the results. The radius of the circle is determined by the `aroundRadius` and `minimumAroundRadius` settings. This parameter is ignored if you also specify `insidePolygon` or `insideBoundingBox`.
    • setAroundLatLngViaIP

      public BaseSearchParamsWithoutQuery setAroundLatLngViaIP(Boolean aroundLatLngViaIP)
    • getAroundLatLngViaIP

      @Nullable public Boolean getAroundLatLngViaIP()
      Whether to obtain the coordinates from the request's IP address.
    • setAroundRadius

      public BaseSearchParamsWithoutQuery setAroundRadius(AroundRadius aroundRadius)
    • getAroundRadius

      @Nullable public AroundRadius getAroundRadius()
      Get aroundRadius
    • setAroundPrecision

      public BaseSearchParamsWithoutQuery setAroundPrecision(AroundPrecision aroundPrecision)
    • getAroundPrecision

      @Nullable public AroundPrecision getAroundPrecision()
      Get aroundPrecision
    • setMinimumAroundRadius

      public BaseSearchParamsWithoutQuery setMinimumAroundRadius(Integer minimumAroundRadius)
    • getMinimumAroundRadius

      @Nullable public Integer getMinimumAroundRadius()
      Minimum radius (in meters) for a search around a location when `aroundRadius` isn't set. minimum: 1
    • setInsideBoundingBox

      public BaseSearchParamsWithoutQuery setInsideBoundingBox(List<List<Double>> insideBoundingBox)
    • addInsideBoundingBox

      public BaseSearchParamsWithoutQuery addInsideBoundingBox(List<Double> insideBoundingBoxItem)
    • getInsideBoundingBox

      @Nullable public List<List<Double>> getInsideBoundingBox()
      Coordinates for a rectangular area in which to search. Each bounding box is defined by the two opposite points of its diagonal, and expressed as latitude and longitude pair: `[p1 lat, p1 long, p2 lat, p2 long]`. Provide multiple bounding boxes as nested arrays. For more information, see [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas).
    • setInsidePolygon

      public BaseSearchParamsWithoutQuery setInsidePolygon(List<List<Double>> insidePolygon)
    • addInsidePolygon

      public BaseSearchParamsWithoutQuery addInsidePolygon(List<Double> insidePolygonItem)
    • getInsidePolygon

      @Nullable public List<List<Double>> getInsidePolygon()
      Coordinates of a polygon in which to search. Polygons are defined by 3 to 10,000 points. Each point is represented by its latitude and longitude. Provide multiple polygons as nested arrays. For more information, see [filtering inside polygons](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas). This parameter is ignored if you also specify `insideBoundingBox`.
    • setNaturalLanguages

      public BaseSearchParamsWithoutQuery setNaturalLanguages(List<SupportedLanguage> naturalLanguages)
    • addNaturalLanguages

      public BaseSearchParamsWithoutQuery addNaturalLanguages(SupportedLanguage naturalLanguagesItem)
    • getNaturalLanguages

      @Nullable public List<SupportedLanguage> getNaturalLanguages()
      ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches): - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
    • setRuleContexts

      public BaseSearchParamsWithoutQuery setRuleContexts(List<String> ruleContexts)
    • addRuleContexts

      public BaseSearchParamsWithoutQuery addRuleContexts(String ruleContextsItem)
    • getRuleContexts

      @Nullable public List<String> getRuleContexts()
      Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) are strings that you can use to trigger matching rules.
    • setPersonalizationImpact

      public BaseSearchParamsWithoutQuery setPersonalizationImpact(Integer personalizationImpact)
    • getPersonalizationImpact

      @Nullable public Integer getPersonalizationImpact()
      Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact). minimum: 0 maximum: 100
    • setUserToken

      public BaseSearchParamsWithoutQuery setUserToken(String userToken)
    • getUserToken

      @Nullable public String getUserToken()
      Unique pseudonymous or anonymous user identifier. This helps with analytics and click and conversion events. For more information, see [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).
    • setGetRankingInfo

      public BaseSearchParamsWithoutQuery setGetRankingInfo(Boolean getRankingInfo)
    • getGetRankingInfo

      @Nullable public Boolean getGetRankingInfo()
      Whether the search response should include detailed ranking information.
    • setSynonyms

      public BaseSearchParamsWithoutQuery setSynonyms(Boolean synonyms)
    • getSynonyms

      @Nullable public Boolean getSynonyms()
      Whether to take into account an index's synonyms for this search.
    • setClickAnalytics

      public BaseSearchParamsWithoutQuery setClickAnalytics(Boolean clickAnalytics)
    • getClickAnalytics

      @Nullable public Boolean getClickAnalytics()
      Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/guides/sending-events/getting-started/).
    • setAnalytics

      public BaseSearchParamsWithoutQuery setAnalytics(Boolean analytics)
    • getAnalytics

      @Nullable public Boolean getAnalytics()
      Whether this search will be included in Analytics.
    • setAnalyticsTags

      public BaseSearchParamsWithoutQuery setAnalyticsTags(List<String> analyticsTags)
    • addAnalyticsTags

      public BaseSearchParamsWithoutQuery addAnalyticsTags(String analyticsTagsItem)
    • getAnalyticsTags

      @Nullable public List<String> getAnalyticsTags()
      Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
    • setPercentileComputation

      public BaseSearchParamsWithoutQuery setPercentileComputation(Boolean percentileComputation)
    • getPercentileComputation

      @Nullable public Boolean getPercentileComputation()
      Whether to include this search when calculating processing-time percentiles.
    • setEnableABTest

      public BaseSearchParamsWithoutQuery setEnableABTest(Boolean enableABTest)
    • getEnableABTest

      @Nullable public Boolean getEnableABTest()
      Whether to enable A/B testing for this search.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object