projects
/
smartthings-infrastructure.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b5602bd
)
Fixing a bug with capabilityMap extraction.
author
rtrimana
<rtrimana@uci.edu>
Tue, 30 Jul 2019 21:58:39 +0000
(14:58 -0700)
committer
rtrimana
<rtrimana@uci.edu>
Tue, 30 Jul 2019 21:58:39 +0000
(14:58 -0700)
Extractor/ExtractorScript.py
patch
|
blob
|
history
diff --git
a/Extractor/ExtractorScript.py
b/Extractor/ExtractorScript.py
index 51f753e98fe00dfe97cc30af9ffbcc15656c991e..f89c9ea42c62dc7fdcdd1059117e7c379069e43d 100644
(file)
--- a/
Extractor/ExtractorScript.py
+++ b/
Extractor/ExtractorScript.py
@@
-62,13
+62,14
@@
def ExtractFunctions(F, appName):
#Check input capability
if (Temp == "input"):
#Check input capability
if (Temp == "input"):
- Temp = GetToken(F) #Get '"'
+ while Temp != "\"":
+ Temp = GetToken(F)
variable = GetToken(F)
Temp = GetToken(F) #Get '"'
Temp = GetToken(F) #Get ','
variable = GetToken(F)
Temp = GetToken(F) #Get '"'
Temp = GetToken(F) #Get ','
- Temp = GetToken(F) #Get '"'
- Temp = GetToken(F) #Get capability...
- capability =
Temp
+ while Temp != "\"":
+ Temp = GetToken(F)
+ capability =
GetToken(F)
capabilityMap[variable] = capability
#Check subscribed events
capabilityMap[variable] = capability
#Check subscribed events
@@
-226,7
+227,10
@@
def ExtractEvents(extractedEvents):
extractedEvents.write("\t\t\t}\n")
elif eventList[i] == "presence":
#Check which capability
extractedEvents.write("\t\t\t}\n")
elif eventList[i] == "presence":
#Check which capability
+ print eventVarMap
+ print capabilityMap
variable = eventVarMap[eventList[i]]
variable = eventVarMap[eventList[i]]
+ print "DEBUG: %s" % variable
capability = capabilityMap[variable]
#Write three events subsequently
extractedEvents.write("\t\t\tdef event = Verify.getInt(0,2)\n")
capability = capabilityMap[variable]
#Write three events subsequently
extractedEvents.write("\t\t\tdef event = Verify.getInt(0,2)\n")