org.apache.lucene.benchmark.byTask.tasks

## Class SearchTravRetLoadFieldSelectorTask

- java.lang.Object
- - org.apache.lucene.benchmark.byTask.tasks.PerfTask
  - - org.apache.lucene.benchmark.byTask.tasks.ReadTask
    - - org.apache.lucene.benchmark.byTask.tasks.SearchTravTask
      - - org.apache.lucene.benchmark.byTask.tasks.SearchTravRetLoadFieldSelectorTask

- All Implemented Interfaces:
    java.lang.Cloneable

      public class SearchTravRetLoadFieldSelectorTask
      extends SearchTravTask

  Search and Traverse and Retrieve docs task using a SetBasedFieldSelector.

  Note: This task reuses the reader if it is already open. Otherwise a reader is opened at start and closed at the end.

  Takes optional param: comma separated list of Fields to load.

  Other side effects: counts additional 1 (record) for each traversed hit, and 1 more for each retrieved (non null) document.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected FieldSelector` | `fieldSelector`

    - ### Fields inherited from class org.apache.lucene.benchmark.byTask.tasks.SearchTravTask

      `traversalSize`

    - ### Fields inherited from class org.apache.lucene.benchmark.byTask.tasks.PerfTask

      `logStep, NEW_LINE, params`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SearchTravRetLoadFieldSelectorTask(PerfRunData runData)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Document` | `retrieveDoc(IndexReader ir, int id)`
    `void` | `setParams(java.lang.String params)` Set the params of this task.
    `boolean` | `supportsParams()` Sub classes that supports parameters must override this method to return true.
    `boolean` | `withRetrieve()` Return true if, with search & results traversing, docs should be retrieved.

    - ### Methods inherited from class org.apache.lucene.benchmark.byTask.tasks.SearchTravTask

      `getQueryMaker, traversalSize, withSearch, withTraverse, withWarm`

    - ### Methods inherited from class org.apache.lucene.benchmark.byTask.tasks.ReadTask

      `doLogic, getBenchmarkHighlighter, getFieldsToHighlight, getSort, numHits, numToHighlight, setup, withMaxScore, withScore`

    - ### Methods inherited from class org.apache.lucene.benchmark.byTask.tasks.PerfTask

      `clone, close, getDepth, getLogMessage, getName, getParams, getRunData, isDisableCounting, runAndMaybeStats, setDepth, setDisableCounting, setName, shouldNeverLogAtStart, shouldNotRecordStats, tearDown, toString`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### fieldSelector

          protected FieldSelector fieldSelector

  - ### Constructor Detail

    - #### SearchTravRetLoadFieldSelectorTask

          public SearchTravRetLoadFieldSelectorTask(PerfRunData runData)

  - ### Method Detail

    - #### withRetrieve

          public boolean withRetrieve()

      Description copied from class: `ReadTask`
      Return true if, with search & results traversing, docs should be retrieved.
      Overrides:
        `withRetrieve` in class `SearchTravTask`

    - #### retrieveDoc

          protected Document retrieveDoc(IndexReader ir,
                                         int id)
                                  throws java.io.IOException

      Overrides:
        `retrieveDoc` in class `ReadTask`
      Throws:
        `java.io.IOException`

    - #### setParams

          public void setParams(java.lang.String params)

      Description copied from class: `PerfTask`
      Set the params of this task.
      Overrides:
        `setParams` in class `SearchTravTask`

    - #### supportsParams

          public boolean supportsParams()

      Description copied from class: `PerfTask`
      Sub classes that supports parameters must override this method to return true.
      Overrides:
        `supportsParams` in class `SearchTravTask`
      Returns:
        true iff this task supports command line params.

Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.