Class ExplainRequest

All Implemented Interfaces:

public class ExplainRequest
extends RequestBase
implements JsonpSerializable
Returns information about why a specific matches (or doesn't match) a query.
See Also:
API specification
  • Field Details

  • Method Details

    • of

      public static ExplainRequest of​(java.util.function.Function<ExplainRequest.Builder,​ObjectBuilder<ExplainRequest>> fn)
    • source

      @Nullable public final SourceConfigParam source()
      True or false to return the _source field or not, or a list of fields to return

      API name: _source

    • sourceExcludes

      public final java.util.List<java.lang.String> sourceExcludes()
      A list of fields to exclude from the returned _source field

      API name: _source_excludes

    • sourceIncludes

      public final java.util.List<java.lang.String> sourceIncludes()
      A list of fields to extract and return from the _source field

      API name: _source_includes

    • analyzeWildcard

      @Nullable public final java.lang.Boolean analyzeWildcard()
      Specify whether wildcards and prefix queries in the query string query should be analyzed (default: false)

      API name: analyze_wildcard

    • analyzer

      @Nullable public final java.lang.String analyzer()
      The analyzer for the query string query

      API name: analyzer

    • defaultOperator

      @Nullable public final Operator defaultOperator()
      The default operator for query string query (AND or OR)

      API name: default_operator

    • df

      @Nullable public final java.lang.String df()
      The default field for query string query (default: _all)

      API name: df

    • id

      public final java.lang.String id()
      Required - The document ID

      API name: id

    • index

      public final java.lang.String index()
      Required - The name of the index

      API name: index

    • lenient

      @Nullable public final java.lang.Boolean lenient()
      Specify whether format-based query failures (such as providing text to a numeric field) should be ignored

      API name: lenient

    • preference

      @Nullable public final java.lang.String preference()
      Specify the node or shard the operation should be performed on (default: random)

      API name: preference

    • q

      @Nullable public final java.lang.String q()
      Query in the Lucene query string syntax

      API name: q

    • query

      @Nullable public final Query query()
      API name: query
    • routing

      @Nullable public final java.lang.String routing()
      Specific routing value

      API name: routing

    • storedFields

      public final java.util.List<java.lang.String> storedFields()
      A comma-separated list of stored fields to return in the response

      API name: stored_fields

    • type

      @Nullable public final java.lang.String type()
      The type of the document

      API name: type

    • serialize

      public void serialize​( generator, JsonpMapper mapper)
      Serialize this object to JSON.
      Specified by:
      serialize in interface JsonpSerializable
    • serializeInternal

      protected void serializeInternal​( generator, JsonpMapper mapper)
    • setupExplainRequestDeserializer

      protected static void setupExplainRequestDeserializer​(ObjectDeserializer<ExplainRequest.Builder> op)
    • createExplainEndpoint

      public static <TDocument> Endpoint<ExplainRequest,​ExplainResponse<TDocument>,​ErrorResponse> createExplainEndpoint​(JsonpDeserializer<TDocument> tDocumentDeserializer)
      Create an "explain" endpoint.