Class AbstractFtsQuery

java.lang.Object
com.couchbase.client.java.search.queries.AbstractFtsQuery
Direct Known Subclasses:
AbstractCompoundQuery, BooleanFieldQuery, BooleanQuery, DateRangeQuery, DocIdQuery, GeoBoundingBoxQuery, GeoDistanceQuery, GeoPolygonQuery, MatchAllQuery, MatchNoneQuery, MatchPhraseQuery, MatchQuery, NumericRangeQuery, PhraseQuery, PrefixQuery, QueryStringQuery, RegexpQuery, TermQuery, TermRangeQuery, WildcardQuery

@Uncommitted
@Private
public abstract class AbstractFtsQuery
extends Object
A base class for all FTS query classes. Exposes the common FTS query parameters. In order to instantiate various flavors of queries, look at concrete classes or static factory methods in SearchQuery.
Since:
2.3.0
Author:
Simon Baslé, Michael Nitschinger
  • Constructor Details

    • AbstractFtsQuery

      protected AbstractFtsQuery()
  • Method Details

    • boost

      public AbstractFtsQuery boost​(double boost)
    • injectParamsAndBoost

      public void injectParamsAndBoost​(JsonObject input)
      Injects the query's parameters (including the common boost and query-specific parameters) into a prepared JsonObject.
      Parameters:
      input - the prepared JsonObject to receive the parameters.
      See Also:
      for a usage of this method.
    • injectParams

      protected abstract void injectParams​(JsonObject input)
      Override to inject query-specific parameters when doing the SearchQuery.export().
      Parameters:
      input - the prepared JsonObject that will represent the query.
    • toString

      public String toString()
      Overrides:
      toString in class Object
      Returns:
      the String representation of the FTS query, which is its JSON representation without global parameters.