diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2015-10-04 16:53:14 +1300 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2015-10-04 16:53:14 +1300 |
commit | c64a77edfdcd6ed4e7cb61bef5e3f2762a607da7 (patch) | |
tree | 470f3e9d8ceae5f8fe7eadc69bf82f9ef8368c6e /src/org/traccar/protocol/EasyTrackProtocolDecoder.java | |
parent | 65d2e3b04e3d32245456e7520796cdf7e9def692 (diff) | |
download | trackermap-server-c64a77edfdcd6ed4e7cb61bef5e3f2762a607da7.tar.gz trackermap-server-c64a77edfdcd6ed4e7cb61bef5e3f2762a607da7.tar.bz2 trackermap-server-c64a77edfdcd6ed4e7cb61bef5e3f2762a607da7.zip |
Replace valueOf with parseXxx
Diffstat (limited to 'src/org/traccar/protocol/EasyTrackProtocolDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/EasyTrackProtocolDecoder.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/org/traccar/protocol/EasyTrackProtocolDecoder.java b/src/org/traccar/protocol/EasyTrackProtocolDecoder.java index 3b07380ea..809850370 100644 --- a/src/org/traccar/protocol/EasyTrackProtocolDecoder.java +++ b/src/org/traccar/protocol/EasyTrackProtocolDecoder.java @@ -20,7 +20,6 @@ import java.util.Calendar; import java.util.TimeZone; import java.util.regex.Matcher; import java.util.regex.Pattern; - import org.jboss.netty.channel.Channel; import org.traccar.BaseProtocolDecoder; import org.traccar.model.Event; @@ -118,7 +117,7 @@ public class EasyTrackProtocolDecoder extends BaseProtocolDecoder { position.set("signal", parser.group(index++)); // Power - position.set(Event.KEY_POWER, Double.valueOf(parser.group(index++))); + position.set(Event.KEY_POWER, Double.parseDouble(parser.group(index++))); // Oil position.set("oil", Integer.parseInt(parser.group(index++), 16)); @@ -129,7 +128,7 @@ public class EasyTrackProtocolDecoder extends BaseProtocolDecoder { // Altitude String altitude = parser.group(index++); if (altitude != null) { - position.setAltitude(Double.valueOf(altitude)); + position.setAltitude(Double.parseDouble(altitude)); } return position; } |