Package net.pl3x.map.core.markers.marker
Class Circle
- All Implemented Interfaces:
JsonSerializable
Represents a circle marker.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
static Circle
fromJson
(com.google.gson.JsonObject obj) Get the centerPoint
of this circle.double
Get the radius of this circle.int
hashCode()
static Circle
Create a new circle.static Circle
Create a new circle.Set a new centerPoint
for this circle.setRadius
(double radius) Set the radius for this circle.com.google.gson.JsonObject
toJson()
Jsonify this object.toString()
Methods inherited from class net.pl3x.map.core.markers.marker.Marker
circle, circle, ellipse, ellipse, ellipse, ellipse, ellipse, ellipse, ellipse, ellipse, getOptions, getPane, getType, icon, icon, icon, icon, icon, icon, icon, multiPolygon, multiPolygon, multiPolygon, multiPolyline, multiPolyline, multiPolyline, polygon, polygon, polygon, polyline, polyline, polyline, rectangle, rectangle, setOptions, setOptions, setPane
-
Constructor Details
-
Circle
Create a new circle.- Parameters:
key
- identifying keycenterX
- center x locationcenterZ
- center z locationradius
- circle radius
-
Circle
Create a new circle.- Parameters:
key
- identifying keycenter
- center locationradius
- circle radius
-
-
Method Details
-
of
Create a new circle.- Parameters:
key
- identifying keycenterX
- center x locationcenterZ
- center z locationradius
- circle radius- Returns:
- a new circle
-
of
Create a new circle.- Parameters:
key
- identifying keycenter
- center locationradius
- circle radius- Returns:
- a new circle
-
getCenter
Get the centerPoint
of this circle.- Returns:
- center point
-
setCenter
Set a new centerPoint
for this circle.- Parameters:
center
- new center- Returns:
- this circle
-
getRadius
public double getRadius()Get the radius of this circle.- Returns:
- radius
-
setRadius
Set the radius for this circle.- Parameters:
radius
- new radius- Returns:
- this circle
-
toJson
public com.google.gson.JsonObject toJson()Description copied from interface:JsonSerializable
Jsonify this object.- Returns:
- object as json element
-
fromJson
-
equals
-
hashCode
public int hashCode() -
toString
-