Fixing bug in Mobile Presence class
[smartthings-infrastructure.git] / Event / Event.groovy
index d7abdf490dbb9658f191c955369e06536eecf2e1..e7956c2a35c2f0f6762d3e38afc942c8574212cb 100644 (file)
@@ -18,6 +18,7 @@ public class Event {
        private double doubleValue
        private boolean physical
        private def date
+       private boolean isManualTransaction
        
        Event(String value, String name, String deviceId, String descriptionText, boolean displayed, String linkText, String displayName, boolean isStateChange, String unit, String data) {
                this.deviceId = deviceId
@@ -36,9 +37,13 @@ public class Event {
                        if (dot != -1)
                        value = value.substring(0, dot)
                        this.integerValue = value.toInteger()
-                       this.doubleValue = Double.parseDouble(value);           
+                       this.doubleValue = Double.parseDouble(value);
                }
                this.physical = true
                this.date = new Date()
        }
+
+       void setManualTransaction(boolean isTrue) {
+               isManualTransaction = isTrue;
+       }
 }