var req = org.argeo.slc.ria.SlcApi.getLoadExecutionDescriptorService(agentUuid,moduleData.name, moduleData.version);
req.addListener("completed", function(response){
var req = org.argeo.slc.ria.SlcApi.getLoadExecutionDescriptorService(agentUuid,moduleData.name, moduleData.version);
req.addListener("completed", function(response){
- var executionModule = new org.argeo.slc.ria.execution.Module();
- executionModule.setXmlNode(response.getContent());
+ var executionModule = new org.argeo.slc.ria.execution.Module();
+ try{
+ executionModule.setXmlNode(response.getContent());
+ }catch(e){
+ this.error(e);
+ }
var execFlows = executionModule.getExecutionFlows();
for(var key in execFlows){
var file = new qx.ui.tree.TreeFile(key);
var execFlows = executionModule.getExecutionFlows();
for(var key in execFlows){
var file = new qx.ui.tree.TreeFile(key);
* The values to init the ExecutionSpec\r
*/\r
values : {\r
* The values to init the ExecutionSpec\r
*/\r
values : {\r
+ check : "Node",\r
+ nullable : true\r
},\r
/**\r
* Castor representation of the object \r
},\r
/**\r
* Castor representation of the object \r
executionSpecName : org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_EXEC_SPEC_NAME)\r
});\r
var values = org.argeo.ria.util.Element.selectNodes(xmlNode, this.self(arguments).XPATH_VALUES);\r
executionSpecName : org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_EXEC_SPEC_NAME)\r
});\r
var values = org.argeo.ria.util.Element.selectNodes(xmlNode, this.self(arguments).XPATH_VALUES);\r
- this.setValues(values[0]);\r
+ if(values[0]){\r
+ this.setValues(values[0]);\r
+ }\r
},\r
/**\r
* Get a given value inside the values map\r
},\r
/**\r
* Get a given value inside the values map\r
*/\r
_applyXmlNode : function(xmlNode){\r
// Parse now\r
*/\r
_applyXmlNode : function(xmlNode){\r
// Parse now\r
- this.setName(org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_NAME));\r
+ this.setName(org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_NAME) || "Not Found");\r
this.setVersion(org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_VERSION));\r
// Parse Specs first\r
var specs = org.argeo.ria.util.Element.selectNodes(xmlNode, this.self(arguments).XPATH_EXECUTION_SPECS);\r
this.setVersion(org.argeo.ria.util.Element.getSingleNodeText(xmlNode, this.self(arguments).XPATH_VERSION));\r
// Parse Specs first\r
var specs = org.argeo.ria.util.Element.selectNodes(xmlNode, this.self(arguments).XPATH_EXECUTION_SPECS);\r
if(child.nodeType != 1) continue;\r
if(child.nodeName == "slc:primitive-spec-attribute"){\r
this.setSpecType("primitive");\r
if(child.nodeType != 1) continue;\r
if(child.nodeName == "slc:primitive-spec-attribute"){\r
this.setSpecType("primitive");\r
- this.setSpecSubType(org.argeo.ria.util.Element.getSingleNodeText(child, "@type"));\r
+ this.setSpecSubType(org.argeo.ria.util.Element.getSingleNodeText(child, "@type")||"");\r
if(org.argeo.ria.util.Element.getSingleNodeText(child, ".")){\r
this.setValue(org.argeo.ria.util.Element.getSingleNodeText(child, "."));\r
}\r
}else if(child.nodeName == "slc:ref-spec-attribute"){\r
this.setSpecType("ref");\r
if(org.argeo.ria.util.Element.getSingleNodeText(child, ".")){\r
this.setValue(org.argeo.ria.util.Element.getSingleNodeText(child, "."));\r
}\r
}else if(child.nodeName == "slc:ref-spec-attribute"){\r
this.setSpecType("ref");\r
- this.setSpecSubType(org.argeo.ria.util.Element.getSingleNodeText(child, "@targetClassName"));\r
+ this.setSpecSubType(org.argeo.ria.util.Element.getSingleNodeText(child, "@targetClassName")||"");\r
}\r
this.set({\r
parameter : (org.argeo.ria.util.Element.getSingleNodeText(child, "@isParameter")=="true"?true:false),\r
}\r
this.set({\r
parameter : (org.argeo.ria.util.Element.getSingleNodeText(child, "@isParameter")=="true"?true:false),\r