Removed Waypoint default constructor used by testing.

This avoids a null check for Waypoint.getLocation().
This commit is contained in:
Dennis Guse
2020-04-14 07:12:56 +02:00
parent 1a86db0a8b
commit ec39e67a09
8 changed files with 157 additions and 174 deletions
@@ -16,11 +16,6 @@
package de.dennisguse.opentracks.content.data;
import androidx.annotation.VisibleForTesting;
import java.util.ArrayList;
import java.util.List;
import de.dennisguse.opentracks.stats.TrackStatistics;
/**
@@ -40,10 +35,6 @@ public class Track {
private TrackStatistics trackStatistics = new TrackStatistics();
// Location points (which may not have been loaded)
@Deprecated //TODO Is only used by tests
private List<TrackPoint> trackPoints = new ArrayList<>();
public Track() {
}
@@ -94,21 +85,4 @@ public class Track {
public void setTrackStatistics(TrackStatistics trackStatistics) {
this.trackStatistics = trackStatistics;
}
@Deprecated
@VisibleForTesting
public void addTrackPoint(TrackPoint location) {
trackPoints.add(location);
}
@VisibleForTesting
@Deprecated //TODO Only used for testing; can be removed?
public List<TrackPoint> getTrackPoints() {
return trackPoints;
}
@Deprecated //TODO Remove
public void setTrackPoints(ArrayList<TrackPoint> trackPoints) {
this.trackPoints = trackPoints;
}
}