org.apache.lucene.geo

## Class Circle

- java.lang.Object
- - org.apache.lucene.geo.LatLonGeometry
  - - org.apache.lucene.geo.Circle

    public final class Circle
    extends LatLonGeometry

Represents a circle on the earth's surface.

NOTES:

1. Latitude/longitude values must be in decimal degrees.
2. Radius must be in meters.
3. For more advanced GeoSpatial indexing and query operations see the `spatial-extras` module

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

### Field Summary

Fields
`static double` `MAX_RADIUS` Max radius allowed, half of the earth mean radius.

### Constructor Summary

Constructors
Constructor and Description
`Circle(double lat, double lon, double radiusMeters)` Creates a new circle from the supplied latitude/longitude center and a radius in meters..

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `equals(Object o)`
`double` `getLat()` Returns the center's latitude
`double` `getLon()` Returns the center's longitude
`double` `getRadius()` Returns the radius in meters
`int` `hashCode()`
`protected Component2D` `toComponent2D()` get a `Component2D` from this geometry
`String` `toString()`

### Methods inherited from class org.apache.lucene.geo.LatLonGeometry

`create`

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

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

### Field Detail

#### MAX_RADIUS

    public static double MAX_RADIUS

Max radius allowed, half of the earth mean radius.

### Constructor Detail

#### Circle

    public Circle(double lat,
                  double lon,
                  double radiusMeters)

Creates a new circle from the supplied latitude/longitude center and a radius in meters..

### Method Detail

#### getLat

    public double getLat()

Returns the center's latitude

#### getLon

    public double getLon()

Returns the center's longitude

#### getRadius

    public double getRadius()

Returns the radius in meters

#### toComponent2D

    protected Component2D toComponent2D()

Description copied from class: `LatLonGeometry`
get a `Component2D` from this geometry

Specified by:
  `toComponent2D` in class `LatLonGeometry`

#### equals

    public boolean equals(Object o)

Overrides:
  `equals` in class `Object`

#### hashCode

    public int hashCode()

Overrides:
  `hashCode` in class `Object`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`