aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/protocol/AtrackProtocol.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/traccar/protocol/AtrackProtocol.java')
-rw-r--r--src/main/java/org/traccar/protocol/AtrackProtocol.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main/java/org/traccar/protocol/AtrackProtocol.java b/src/main/java/org/traccar/protocol/AtrackProtocol.java
index 65cd5194e..21eb09696 100644
--- a/src/main/java/org/traccar/protocol/AtrackProtocol.java
+++ b/src/main/java/org/traccar/protocol/AtrackProtocol.java
@@ -21,12 +21,15 @@ import org.traccar.TrackerServer;
import org.traccar.config.Config;
import org.traccar.model.Command;
+import javax.inject.Inject;
+
public class AtrackProtocol extends BaseProtocol {
- public AtrackProtocol() {
+ @Inject
+ public AtrackProtocol(Config config) {
setSupportedDataCommands(
Command.TYPE_CUSTOM);
- addServer(new TrackerServer(false, getName()) {
+ addServer(new TrackerServer(config, getName(), false) {
@Override
protected void addProtocolHandlers(PipelineBuilder pipeline, Config config) {
pipeline.addLast(new AtrackFrameDecoder());
@@ -34,7 +37,7 @@ public class AtrackProtocol extends BaseProtocol {
pipeline.addLast(new AtrackProtocolDecoder(AtrackProtocol.this));
}
});
- addServer(new TrackerServer(true, getName()) {
+ addServer(new TrackerServer(config, getName(), true) {
@Override
protected void addProtocolHandlers(PipelineBuilder pipeline, Config config) {
pipeline.addLast(new AtrackProtocolEncoder(AtrackProtocol.this));