diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2016-04-27 11:21:27 +1200 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2016-04-27 11:21:27 +1200 |
commit | 44f026f881efa6207ab79fb5bada20ab67f018a0 (patch) | |
tree | 62cab9dc7d35c12bf75217eecf85b335ecebbe5a /src/org/traccar/protocol/HuabaoProtocolDecoder.java | |
parent | aa0cbaa6e849d01a5bb02e2e999b80c178270014 (diff) | |
download | trackermap-server-44f026f881efa6207ab79fb5bada20ab67f018a0.tar.gz trackermap-server-44f026f881efa6207ab79fb5bada20ab67f018a0.tar.bz2 trackermap-server-44f026f881efa6207ab79fb5bada20ab67f018a0.zip |
Rename ChannelBufferTools to BcdUtil
Diffstat (limited to 'src/org/traccar/protocol/HuabaoProtocolDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/HuabaoProtocolDecoder.java | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/org/traccar/protocol/HuabaoProtocolDecoder.java b/src/org/traccar/protocol/HuabaoProtocolDecoder.java index a9a4741fc..6ed490c1a 100644 --- a/src/org/traccar/protocol/HuabaoProtocolDecoder.java +++ b/src/org/traccar/protocol/HuabaoProtocolDecoder.java @@ -19,8 +19,8 @@ import org.jboss.netty.buffer.ChannelBuffer; import org.jboss.netty.buffer.ChannelBuffers; import org.jboss.netty.channel.Channel; import org.traccar.BaseProtocolDecoder; +import org.traccar.helper.BcdUtil; import org.traccar.helper.BitUtil; -import org.traccar.helper.ChannelBufferTools; import org.traccar.helper.Checksum; import org.traccar.helper.DateBuilder; import org.traccar.helper.UnitsConverter; @@ -132,12 +132,12 @@ public class HuabaoProtocolDecoder extends BaseProtocolDecoder { position.setCourse(buf.readUnsignedShort()); DateBuilder dateBuilder = new DateBuilder(TimeZone.getTimeZone("GMT+8")) - .setYear(ChannelBufferTools.readHexInteger(buf, 2)) - .setMonth(ChannelBufferTools.readHexInteger(buf, 2)) - .setDay(ChannelBufferTools.readHexInteger(buf, 2)) - .setHour(ChannelBufferTools.readHexInteger(buf, 2)) - .setMinute(ChannelBufferTools.readHexInteger(buf, 2)) - .setSecond(ChannelBufferTools.readHexInteger(buf, 2)); + .setYear(BcdUtil.readInteger(buf, 2)) + .setMonth(BcdUtil.readInteger(buf, 2)) + .setDay(BcdUtil.readInteger(buf, 2)) + .setHour(BcdUtil.readInteger(buf, 2)) + .setMinute(BcdUtil.readInteger(buf, 2)) + .setSecond(BcdUtil.readInteger(buf, 2)); position.setTime(dateBuilder.getDate()); // additional information |