Class TermVectorsRequest

java.lang.Object
org.elasticsearch.client.core.TermVectorsRequest
All Implemented Interfaces:
Validatable, org.elasticsearch.common.xcontent.ToXContent, org.elasticsearch.common.xcontent.ToXContentObject

public class TermVectorsRequest extends Object implements org.elasticsearch.common.xcontent.ToXContentObject, Validatable
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent

    org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.Params
  • Field Summary

    Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent

    EMPTY_PARAMS

    Fields inherited from interface org.elasticsearch.client.Validatable

    EMPTY
  • Constructor Summary

    Constructors
    Constructor
    Description
    TermVectorsRequest​(String index, String docId)
    Constructs TermVectorRequest for the given document
    TermVectorsRequest​(String index, String type, String docId)
    Deprecated.
    Types are in the process of being removed, use TermVectorsRequest(String, String) instead.
    TermVectorsRequest​(String index, String type, org.elasticsearch.common.xcontent.XContentBuilder docBuilder)
    Deprecated.
    TermVectorsRequest​(String index, org.elasticsearch.common.xcontent.XContentBuilder docBuilder)
    Constructs TermVectorRequest for an artificial document
  • Method Summary

    Modifier and Type
    Method
    Description
     
    Returns the id of the request can be NULL if there is no document ID
    Returns the index of the request
     
    boolean
    Returns if the request is realtime(true) or near-realtime(false)
     
    Deprecated.
    Types are in the process of being removed.
    void
    setFields​(String... fields)
    Sets the fields for which term vectors information should be retrieved
    void
    setFieldStatistics​(boolean requestFieldStatistics)
    Sets whether to request field statistics
    void
    setFilterSettings​(Map<String,​Integer> filterSettings)
    Sets conditions for terms filtering
    void
    setOffsets​(boolean requestOffsets)
    Sets whether to request term offsets
    void
    setPayloads​(boolean requestPayloads)
    Sets whether to request term payloads
    void
    setPerFieldAnalyzer​(Map<String,​String> perFieldAnalyzer)
    Sets different analyzers than the one at the fields
    void
    setPositions​(boolean requestPositions)
    Sets whether to request term positions
    void
    setPreference​(String preference)
    Set a preference of which shard copies to execute the request
    void
    setRealtime​(boolean realtime)
    Sets if the request should be realtime or near-realtime
    void
    setRouting​(String routing)
    Sets a routing to route a request to a particular shard
    void
    setTermStatistics​(boolean requestTermStatistics)
    Sets whether to request term statistics
    org.elasticsearch.common.xcontent.XContentBuilder
    toXContent​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject

    isFragment

    Methods inherited from interface org.elasticsearch.client.Validatable

    validate
  • Constructor Details

    • TermVectorsRequest

      public TermVectorsRequest(String index, String docId)
      Constructs TermVectorRequest for the given document
      Parameters:
      index - - index of the document
      docId - - id of the document
    • TermVectorsRequest

      @Deprecated public TermVectorsRequest(String index, String type, String docId)
      Deprecated.
      Types are in the process of being removed, use TermVectorsRequest(String, String) instead.
      Constructs TermVectorRequest for the given document
      Parameters:
      index - - index of the document
      type - - type of the document
      docId - - id of the document
    • TermVectorsRequest

      public TermVectorsRequest(String index, org.elasticsearch.common.xcontent.XContentBuilder docBuilder)
      Constructs TermVectorRequest for an artificial document
      Parameters:
      index - - index of the document
      docBuilder - - an artificial document
    • TermVectorsRequest

      @Deprecated public TermVectorsRequest(String index, String type, org.elasticsearch.common.xcontent.XContentBuilder docBuilder)
      Deprecated.
      Constructs TermVectorRequest for an artificial document
      Parameters:
      index - - index of the document
      type - - type of the document
      docBuilder - - an artificial document
  • Method Details

    • getIndex

      public String getIndex()
      Returns the index of the request
    • getType

      @Deprecated public String getType()
      Deprecated.
      Types are in the process of being removed.
      Returns the type of the request
    • getId

      public String getId()
      Returns the id of the request can be NULL if there is no document ID
    • setFields

      public void setFields(String... fields)
      Sets the fields for which term vectors information should be retrieved
    • getFields

      public String[] getFields()
    • setPositions

      public void setPositions(boolean requestPositions)
      Sets whether to request term positions
    • setPayloads

      public void setPayloads(boolean requestPayloads)
      Sets whether to request term payloads
    • setOffsets

      public void setOffsets(boolean requestOffsets)
      Sets whether to request term offsets
    • setFieldStatistics

      public void setFieldStatistics(boolean requestFieldStatistics)
      Sets whether to request field statistics
    • setTermStatistics

      public void setTermStatistics(boolean requestTermStatistics)
      Sets whether to request term statistics
    • setPerFieldAnalyzer

      public void setPerFieldAnalyzer(Map<String,​String> perFieldAnalyzer)
      Sets different analyzers than the one at the fields
    • setFilterSettings

      public void setFilterSettings(Map<String,​Integer> filterSettings)
      Sets conditions for terms filtering
    • setRouting

      public void setRouting(String routing)
      Sets a routing to route a request to a particular shard
    • getRouting

      public String getRouting()
    • setPreference

      public void setPreference(String preference)
      Set a preference of which shard copies to execute the request
    • getPreference

      public String getPreference()
    • setRealtime

      public void setRealtime(boolean realtime)
      Sets if the request should be realtime or near-realtime
    • getRealtime

      public boolean getRealtime()
      Returns if the request is realtime(true) or near-realtime(false)
    • toXContent

      public org.elasticsearch.common.xcontent.XContentBuilder toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws IOException
      Specified by:
      toXContent in interface org.elasticsearch.common.xcontent.ToXContent
      Throws:
      IOException