aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/Context.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2016-12-31 11:34:22 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2016-12-31 11:34:22 +1300
commite8cd15c0fb192f635808adfde4e8614e6b4b3c3f (patch)
tree74a41d42c37d9a6b4756c6bddb90ec43c75ffd5b /src/org/traccar/Context.java
parentd13f618ee3b8463d063b7f67e039299560245597 (diff)
downloadtrackermap-server-e8cd15c0fb192f635808adfde4e8614e6b4b3c3f.tar.gz
trackermap-server-e8cd15c0fb192f635808adfde4e8614e6b4b3c3f.tar.bz2
trackermap-server-e8cd15c0fb192f635808adfde4e8614e6b4b3c3f.zip
Rename Location to Geolocation
Diffstat (limited to 'src/org/traccar/Context.java')
-rw-r--r--src/org/traccar/Context.java28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/org/traccar/Context.java b/src/org/traccar/Context.java
index 14ef85929..4825158c4 100644
--- a/src/org/traccar/Context.java
+++ b/src/org/traccar/Context.java
@@ -44,10 +44,10 @@ import org.traccar.geocode.NominatimReverseGeocoder;
import org.traccar.geocode.OpenCageReverseGeocoder;
import org.traccar.geocode.ReverseGeocoder;
import org.traccar.helper.Log;
-import org.traccar.location.GoogleLocationProvider;
-import org.traccar.location.LocationProvider;
-import org.traccar.location.MozillaLocationProvider;
-import org.traccar.location.OpenCellIdLocationProvider;
+import org.traccar.geolocation.GoogleGeolocationProvider;
+import org.traccar.geolocation.GeolocationProvider;
+import org.traccar.geolocation.MozillaGeolocationProvider;
+import org.traccar.geolocation.OpenCellIdGeolocationProvider;
import org.traccar.notification.EventForwarder;
import org.traccar.web.WebServer;
@@ -110,10 +110,10 @@ public final class Context {
return reverseGeocoder;
}
- private static LocationProvider locationProvider;
+ private static GeolocationProvider geolocationProvider;
- public static LocationProvider getLocationProvider() {
- return locationProvider;
+ public static GeolocationProvider getGeolocationProvider() {
+ return geolocationProvider;
}
private static WebServer webServer;
@@ -249,20 +249,20 @@ public final class Context {
}
}
- if (config.getBoolean("location.enable")) {
- String type = config.getString("location.type", "mozilla");
- String key = config.getString("location.key");
+ if (config.getBoolean("geolocation.enable")) {
+ String type = config.getString("geolocation.type", "mozilla");
+ String key = config.getString("geolocation.key");
switch (type) {
case "google":
- locationProvider = new GoogleLocationProvider(key);
+ geolocationProvider = new GoogleGeolocationProvider(key);
case "opencellid":
- locationProvider = new OpenCellIdLocationProvider(key);
+ geolocationProvider = new OpenCellIdGeolocationProvider(key);
default:
if (key != null) {
- locationProvider = new MozillaLocationProvider(key);
+ geolocationProvider = new MozillaGeolocationProvider(key);
} else {
- locationProvider = new MozillaLocationProvider();
+ geolocationProvider = new MozillaGeolocationProvider();
}
break;
}