aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/XirgoProtocolDecoder.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/protocol/XirgoProtocolDecoder.java')
-rw-r--r--src/org/traccar/protocol/XirgoProtocolDecoder.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/org/traccar/protocol/XirgoProtocolDecoder.java b/src/org/traccar/protocol/XirgoProtocolDecoder.java
index 8e070694f..f6ae4776b 100644
--- a/src/org/traccar/protocol/XirgoProtocolDecoder.java
+++ b/src/org/traccar/protocol/XirgoProtocolDecoder.java
@@ -81,12 +81,12 @@ public class XirgoProtocolDecoder extends BaseProtocolDecoder {
// Date
Calendar time = Calendar.getInstance(TimeZone.getTimeZone("UTC"));
time.clear();
- time.set(Calendar.YEAR, Integer.valueOf(parser.group(index++)));
- time.set(Calendar.MONTH, Integer.valueOf(parser.group(index++)) - 1);
- time.set(Calendar.DAY_OF_MONTH, Integer.valueOf(parser.group(index++)));
- time.set(Calendar.HOUR_OF_DAY, Integer.valueOf(parser.group(index++)));
- time.set(Calendar.MINUTE, Integer.valueOf(parser.group(index++)));
- time.set(Calendar.SECOND, Integer.valueOf(parser.group(index++)));
+ time.set(Calendar.YEAR, Integer.parseInt(parser.group(index++)));
+ time.set(Calendar.MONTH, Integer.parseInt(parser.group(index++)) - 1);
+ time.set(Calendar.DAY_OF_MONTH, Integer.parseInt(parser.group(index++)));
+ time.set(Calendar.HOUR_OF_DAY, Integer.parseInt(parser.group(index++)));
+ time.set(Calendar.MINUTE, Integer.parseInt(parser.group(index++)));
+ time.set(Calendar.SECOND, Integer.parseInt(parser.group(index++)));
position.setTime(time.getTime());
// Location
@@ -104,7 +104,7 @@ public class XirgoProtocolDecoder extends BaseProtocolDecoder {
position.set(Event.KEY_ODOMETER, parser.group(index++));
// Validity
- position.setValid(Integer.valueOf(parser.group(index++)) == 1);
+ position.setValid(Integer.parseInt(parser.group(index++)) == 1);
return position;
}