aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/GenericProtocolDecoder.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2012-04-02 20:03:08 +0000
committerAnton Tananaev <anton.tananaev@gmail.com>2012-04-02 20:03:08 +0000
commit96beee5caf560e4b441d2d9e2ebba434c70f5f79 (patch)
treeeddcf0977b73ad716fa86dfa33ec00b7fe846847 /src/org/traccar/GenericProtocolDecoder.java
parent932111062285ffdbb8f22a9c25e4946c893a6e71 (diff)
downloadtrackermap-server-96beee5caf560e4b441d2d9e2ebba434c70f5f79.tar.gz
trackermap-server-96beee5caf560e4b441d2d9e2ebba434c70f5f79.tar.bz2
trackermap-server-96beee5caf560e4b441d2d9e2ebba434c70f5f79.zip
Diffstat (limited to 'src/org/traccar/GenericProtocolDecoder.java')
-rw-r--r--src/org/traccar/GenericProtocolDecoder.java30
1 files changed, 25 insertions, 5 deletions
diff --git a/src/org/traccar/GenericProtocolDecoder.java b/src/org/traccar/GenericProtocolDecoder.java
index 0d79818ab..c48cf6c56 100644
--- a/src/org/traccar/GenericProtocolDecoder.java
+++ b/src/org/traccar/GenericProtocolDecoder.java
@@ -35,9 +35,16 @@ public abstract class GenericProtocolDecoder extends OneToOneDecoder {
private DataManager dataManager;
/**
+ * Set data manager
+ */
+ public final void setDataManager(DataManager dataManager) {
+ this.dataManager = dataManager;
+ }
+
+ /**
* Return data manager
*/
- public DataManager getDataManager() {
+ public final DataManager getDataManager() {
return dataManager;
}
@@ -45,14 +52,27 @@ public abstract class GenericProtocolDecoder extends OneToOneDecoder {
* Reset connection delay
*/
private Integer resetDelay;
-
+
/**
- * Initialize variables
+ * Set reset connection delay
*/
- public GenericProtocolDecoder(DataManager dataManager, Integer resetDelay) {
- this.dataManager = dataManager;
+ public final void setResetDelay(Integer resetDelay) {
this.resetDelay = resetDelay;
}
+
+ /**
+ * Default constructor
+ */
+ public GenericProtocolDecoder() {
+ }
+
+ /**
+ * Initialize
+ */
+ public GenericProtocolDecoder(DataManager dataManager, Integer resetDelay) {
+ setDataManager(dataManager);
+ setResetDelay(resetDelay);
+ }
/**
* Disconnect channel