From 73667548d1d83cdfbd6b4a76e0321698cad0fd4b Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Fri, 17 Mar 2017 21:33:16 +1300 Subject: Load XT2400 format from config --- src/org/traccar/protocol/Xt2400ProtocolDecoder.java | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/org/traccar/protocol/Xt2400ProtocolDecoder.java b/src/org/traccar/protocol/Xt2400ProtocolDecoder.java index 76b0b60fe..a42c6175f 100644 --- a/src/org/traccar/protocol/Xt2400ProtocolDecoder.java +++ b/src/org/traccar/protocol/Xt2400ProtocolDecoder.java @@ -18,6 +18,7 @@ package org.traccar.protocol; import org.jboss.netty.buffer.ChannelBuffer; import org.jboss.netty.channel.Channel; import org.traccar.BaseProtocolDecoder; +import org.traccar.Context; import org.traccar.DeviceSession; import org.traccar.helper.UnitsConverter; import org.traccar.model.Position; @@ -34,6 +35,11 @@ public class Xt2400ProtocolDecoder extends BaseProtocolDecoder { public Xt2400ProtocolDecoder(Xt2400Protocol protocol) { super(protocol); + + String config = Context.getConfig().getString(getProtocolName() + ".config"); + if (config != null) { + setConfig(config); + } } private static final Map TAG_LENGTH_MAP = new HashMap<>(); -- cgit v1.2.3