public class GeofenceGeometry extends Object
CIRCULAR
or POLYGON
.
Check instnace type
field to distinguish between them.
Fist one is characterized by radius
and its center position obtained from
getCenterLatitude()
and getCenterLongitude()
or
getCenter()
.
Those getters return null if geofence type isn't CIRCULAR
.
POLYGON
is characterized by its border polyline that is accessible via
getPolygon()
.Modifier and Type | Field and Description |
---|---|
static String |
CIRCULAR |
List<Trip.Point2D> |
points |
static String |
POLYGON |
Integer |
radius |
String |
type |
Modifier and Type | Method and Description |
---|---|
static GeofenceGeometry |
getCircularGeometry(double centerLatitude,
double centerLongitude,
Double centerAltitude,
int radius) |
static GeofenceGeometry |
getPolygonGeometry(List<List<Double>> vertices) |
public static final String CIRCULAR
public static final String POLYGON
public final String type
public final List<Trip.Point2D> points
public final Integer radius
public static GeofenceGeometry getCircularGeometry(double centerLatitude, double centerLongitude, Double centerAltitude, int radius)
public static GeofenceGeometry getPolygonGeometry(List<List<Double>> vertices)