equal
deleted
inserted
replaced
1296 # second section contains all variables |
1296 # second section contains all variables |
1297 for line in ListGroup[1]: |
1297 for line in ListGroup[1]: |
1298 # Split and Maps each field to dictionnary entries |
1298 # Split and Maps each field to dictionnary entries |
1299 attrs = dict(zip(VariablesListAttributeName,line.strip().split(';'))) |
1299 attrs = dict(zip(VariablesListAttributeName,line.strip().split(';'))) |
1300 # Truncate "C_path" to remove conf an ressources names |
1300 # Truncate "C_path" to remove conf an ressources names |
1301 attrs["C_path"] = '__'.join(attrs["C_path"].split(".",2)[1:]) |
1301 parts = attrs["C_path"].split(".",2) |
|
1302 if len(parts) > 2: |
|
1303 attrs["C_path"] = '__'.join(parts[1:]) |
|
1304 else: |
|
1305 attrs["C_path"] = '__'.join(parts) |
1302 # Push this dictionnary into result. |
1306 # Push this dictionnary into result. |
1303 self._VariablesList.append(attrs) |
1307 self._VariablesList.append(attrs) |
1304 # Fill in IEC<->C translation dicts |
1308 # Fill in IEC<->C translation dicts |
1305 IEC_path=attrs["IEC_path"] |
1309 IEC_path=attrs["IEC_path"] |
1306 Idx=int(attrs["num"]) |
1310 Idx=int(attrs["num"]) |