aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/geofence/GeofenceGeometry.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/geofence/GeofenceGeometry.java')
-rw-r--r--src/org/traccar/geofence/GeofenceGeometry.java29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/org/traccar/geofence/GeofenceGeometry.java b/src/org/traccar/geofence/GeofenceGeometry.java
index 6b5b0acb7..d61e357ce 100644
--- a/src/org/traccar/geofence/GeofenceGeometry.java
+++ b/src/org/traccar/geofence/GeofenceGeometry.java
@@ -25,4 +25,33 @@ public abstract class GeofenceGeometry {
public abstract void fromWkt(String wkt) throws ParseException;
+ public static class Coordinate {
+
+ public static final double DEGREE360 = 360;
+
+ private double lat;
+ private double lon;
+
+ public double getLat() {
+ return lat;
+ }
+
+ public void setLat(double lat) {
+ this.lat = lat;
+ }
+
+ public double getLon() {
+ return lon;
+ }
+
+ // Need not to confuse algorithm by the abrupt reset of longitude
+ public double getLon360() {
+ return lon + DEGREE360;
+ }
+
+ public void setLon(double lon) {
+ this.lon = lon;
+ }
+ }
+
}