org.apache.lucene.spatial.tier

## Class DistanceHandler

- java.lang.Object
- - org.apache.lucene.spatial.tier.DistanceHandler

-     public class DistanceHandler
      extends java.lang.Object

  Provide a high level access point to distances Used by DistanceSortSource and DistanceQuery

  NOTE: This API is still in flux and might change in incompatible ways in the next release.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `DistanceHandler.Precision`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DistanceHandler(java.util.Map<java.lang.Integer,java.lang.Double> distances, java.util.Map<java.lang.String,java.lang.Double> distanceLookupCache, DistanceHandler.Precision precise)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `double` | `getDistance(int docid, double centerLat, double centerLng, double lat, double lng)`
    `DistanceHandler.Precision` | `getPrecision()`
    `static double` | `getPrecision(double x, DistanceHandler.Precision thisPrecise)`
    `static void` | `main(java.lang.String[] args)`

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

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

- - ### Constructor Detail

    - #### DistanceHandler

          public DistanceHandler(java.util.Map<java.lang.Integer,java.lang.Double> distances,
                                 java.util.Map<java.lang.String,java.lang.Double> distanceLookupCache,
                                 DistanceHandler.Precision precise)

  - ### Method Detail

    - #### getPrecision

          public static double getPrecision(double x,
                                            DistanceHandler.Precision thisPrecise)

    - #### getPrecision

          public DistanceHandler.Precision getPrecision()

    - #### getDistance

          public double getDistance(int docid,
                                    double centerLat,
                                    double centerLng,
                                    double lat,
                                    double lng)

    - #### main

          public static void main(java.lang.String[] args)

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