org.apache.lucene.bkdtree3d

## Class Geo3DDocValuesFormat

- java.lang.Object
- - org.apache.lucene.codecs.DocValuesFormat
  - - org.apache.lucene.bkdtree3d.Geo3DDocValuesFormat

- All Implemented Interfaces:
    NamedSPILoader.NamedSPI

  Deprecated.
  Use dimensional values in Lucene 6.0 instead

      @Deprecated
      public class Geo3DDocValuesFormat
      extends DocValuesFormat

  A `DocValuesFormat` to efficiently index geo-spatial 3D x,y,z points from `Geo3DPointField` for fast shape intersection queries using (`PointInGeo3DShapeQuery`)

  This wraps `Lucene54DocValuesFormat`, but saves its own BKD tree structures to disk for fast query-time intersection. See this paper for details.

  The BKD tree slices up 3D x,y,z space into smaller and smaller 3D rectangles, until the smallest rectangles have approximately between X/2 and X (X default is 1024) points in them, at which point such leaf cells are written as a block to disk, while the index tree structure records how space was sub-divided is loaded into HEAP at search time. At search time, the tree is recursed based on whether each of left or right child overlap with the query shape, and once a leaf block is reached, all documents in that leaf block are collected if the cell is fully enclosed by the query shape, or filtered and then collected, if not.

  The index is also quite compact, because docs only appear once in the tree (no "prefix terms").

  In addition to the files written by `Lucene54DocValuesFormat`, this format writes:

  1. `.kd3d`: BKD leaf data and index
  2. `.kd3m`: BKD metadata

  The disk format is experimental and free to change suddenly, and this code likely has new and exciting bugs!

  WARNING: This API is experimental and might change in incompatible ways in the next release.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Geo3DDocValuesFormat()` Deprecated. Default constructor
    `Geo3DDocValuesFormat(PlanetModel planetModel, int maxPointsInLeafNode, int maxPointsSortInHeap)` Deprecated. Creates this with custom configuration.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `DocValuesConsumer` | `fieldsConsumer(SegmentWriteState state)` Deprecated.
    `DocValuesProducer` | `fieldsProducer(SegmentReadState state)` Deprecated.

    - ### Methods inherited from class org.apache.lucene.codecs.DocValuesFormat

      `availableDocValuesFormats, forName, getName, reloadDocValuesFormats, toString`

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

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

- - ### Constructor Detail

    - #### Geo3DDocValuesFormat

          public Geo3DDocValuesFormat()

      Deprecated.
      Default constructor

    - #### Geo3DDocValuesFormat

          public Geo3DDocValuesFormat(PlanetModel planetModel,
                              int maxPointsInLeafNode,
                              int maxPointsSortInHeap)

      Deprecated.
      Creates this with custom configuration.
      Parameters:
        `planetModel` - the `PlanetModel` to use; this is only used when writing
        `maxPointsInLeafNode` - Maximum number of points in each leaf cell. Smaller values create a deeper tree with larger in-heap index and possibly faster searching. The default is 1024.
        `maxPointsSortInHeap` - Maximum number of points where in-heap sort can be used. When the number of points exceeds this, a (slower) offline sort is used. The default is 128 * 1024.
      WARNING: This API is experimental and might change in incompatible ways in the next release.

  - ### Method Detail

    - #### fieldsConsumer

          public DocValuesConsumer fieldsConsumer(SegmentWriteState state)
                                           throws IOException

      Deprecated.
      Specified by:
        `fieldsConsumer` in class `DocValuesFormat`
      Throws:
        `IOException`

    - #### fieldsProducer

          public DocValuesProducer fieldsProducer(SegmentReadState state)
                                           throws IOException

      Deprecated.
      Specified by:
        `fieldsProducer` in class `DocValuesFormat`
      Throws:
        `IOException`

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