org.apache.lucene.geo3d

## Interface DistanceStyle

- All Known Implementing Classes:
    ArcDistance, LinearDistance, LinearSquaredDistance, NormalDistance, NormalSquaredDistance

      public interface DistanceStyle

  Distance computation styles, supporting various ways of computing distance to shapes.
  WARNING: This API is experimental and might change in incompatible ways in the next release.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static ArcDistance` | `ARC` Arc distance calculator
    `static LinearDistance` | `LINEAR` Linear distance calculator
    `static LinearSquaredDistance` | `LINEAR_SQUARED` Linear distance squared calculator
    `static NormalDistance` | `NORMAL` Normal distance calculator
    `static NormalSquaredDistance` | `NORMAL_SQUARED` Normal distance squared calculator

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `double` | `computeDistance(GeoPoint point1, double x2, double y2, double z2)` Compute the distance from a point to another point.
    `double` | `computeDistance(GeoPoint point1, GeoPoint point2)` Compute the distance from a point to another point.
    `double` | `computeDistance(PlanetModel planetModel, Plane plane, double x, double y, double z, Membership... bounds)` Compute the distance from a plane to a point.
    `double` | `computeDistance(PlanetModel planetModel, Plane plane, GeoPoint point, Membership... bounds)` Compute the distance from a plane to a point.

- - ### Field Detail

    - #### ARC

          static final ArcDistance ARC

      Arc distance calculator

    - #### LINEAR

          static final LinearDistance LINEAR

      Linear distance calculator

    - #### LINEAR_SQUARED

          static final LinearSquaredDistance LINEAR_SQUARED

      Linear distance squared calculator

    - #### NORMAL

          static final NormalDistance NORMAL

      Normal distance calculator

    - #### NORMAL_SQUARED

          static final NormalSquaredDistance NORMAL_SQUARED

      Normal distance squared calculator

  - ### Method Detail

    - #### computeDistance

          double computeDistance(GeoPoint point1,
                               GeoPoint point2)

      Compute the distance from a point to another point.
      Parameters:
        `point1` - Starting point
        `point2` - Final point
      Returns:
        the distance

    - #### computeDistance

          double computeDistance(GeoPoint point1,
                               double x2,
                               double y2,
                               double z2)

      Compute the distance from a point to another point.
      Parameters:
        `point1` - Starting point
        `x2` - Final point x
        `y2` - Final point y
        `z2` - Final point z
      Returns:
        the distance

    - #### computeDistance

          double computeDistance(PlanetModel planetModel,
                               Plane plane,
                               GeoPoint point,
                               Membership... bounds)

      Compute the distance from a plane to a point.
      Parameters:
        `planetModel` - The planet model
        `plane` - The plane
        `point` - The point
        `bounds` - are the plane bounds
      Returns:
        the distance

    - #### computeDistance

          double computeDistance(PlanetModel planetModel,
                               Plane plane,
                               double x,
                               double y,
                               double z,
                               Membership... bounds)

      Compute the distance from a plane to a point.
      Parameters:
        `planetModel` - The planet model
        `plane` - The plane
        `x` - The point x
        `y` - The point y
        `z` - The point z
        `bounds` - are the plane bounds
      Returns:
        the distance

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