aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar')
-rw-r--r--src/org/traccar/BaseProtocolDecoder.java2
-rw-r--r--src/org/traccar/model/Position.java10
2 files changed, 12 insertions, 0 deletions
diff --git a/src/org/traccar/BaseProtocolDecoder.java b/src/org/traccar/BaseProtocolDecoder.java
index f8abdcc85..bd91f5e09 100644
--- a/src/org/traccar/BaseProtocolDecoder.java
+++ b/src/org/traccar/BaseProtocolDecoder.java
@@ -75,6 +75,8 @@ public abstract class BaseProtocolDecoder extends ExtendedObjectDecoder {
}
public void getLastLocation(Position position, Date deviceTime) {
+ position.setOutdated(true);
+
Position last = Context.getConnectionManager().getLastPosition(getDeviceId());
if (last != null) {
position.setFixTime(last.getFixTime());
diff --git a/src/org/traccar/model/Position.java b/src/org/traccar/model/Position.java
index 1ed559ecd..9494da042 100644
--- a/src/org/traccar/model/Position.java
+++ b/src/org/traccar/model/Position.java
@@ -47,6 +47,16 @@ public class Position extends Event implements Factory {
setFixTime(time);
}
+ private boolean outdated;
+
+ public boolean getOutdated() {
+ return outdated;
+ }
+
+ public void setOutdated(boolean outdated) {
+ this.outdated = outdated;
+ }
+
private boolean valid;
public boolean getValid() {