Class Sphere
java.lang.Object
org.springframework.data.mongodb.core.geo.Sphere
- All Implemented Interfaces:
Serializable,Shape
Represents a geospatial sphere value.
- Since:
- 1.5
- Author:
- Thomas Darimont, Mark Paluch
- See Also:
-
Field Details
-
COMMAND
- See Also:
-
-
Constructor Details
-
Sphere
Creates a Sphere around the given centerPointwith the given radius.- Parameters:
center- must not be null.radius- must not be null.
-
Sphere
Creates a Sphere around the given centerPointwith the given radius.- Parameters:
center- must not be null.radius-
-
Sphere
Creates a Sphere from the givenCircle.- Parameters:
circle- must not be null.
-
-
Method Details
-
getCenter
Returns the center of theCircle.- Returns:
- will never be null.
-
getRadius
Returns the radius of theCircle.- Returns:
- never null.
-
toString
-
equals
-
hashCode
public int hashCode() -
asList
Returns theShapeas a list of usuallyDoubleorLists ofDoubles. Wildcard bound to allow implementations to return a more concrete element type.- Returns:
- never null.
-
getCommand
Returns the command to be used to create the $within criterion.- Returns:
- never null.
-