AT&T 1712 and 1802 release code
[so.git] / bpmn / MSOCommonBPMN / src / main / groovy / org / openecomp / mso / bpmn / common / scripts / AllottedResourceUtils.groovy
index 8e2403c..fc099ca 100644 (file)
@@ -2,14 +2,14 @@ package org.openecomp.mso.bpmn.common.scripts
 \r
 import org.apache.commons.lang3.StringEscapeUtils;\r
 import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution;\r
+import org.camunda.bpm.engine.delegate.DelegateExecution;\r
 import org.openecomp.mso.bpmn.core.WorkflowException\r
 import org.openecomp.mso.rest.APIResponse;\r
 \r
 \r
 import org.apache.commons.lang3.*\r
 import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution;\r
+import org.camunda.bpm.engine.delegate.DelegateExecution;\r
 \r
 import groovy.util.XmlParser\r
 import groovy.util.Node\r
@@ -34,7 +34,7 @@ class AllottedResourceUtils {
        * return: orchStatus - > AR found with this orchStatus\r
        * setsVariable aaiARGetResponse\r
        */\r
-       public String getAROrchStatus (Execution execution) {\r
+       public String getAROrchStatus (DelegateExecution execution) {\r
 \r
                def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG"," ***** getAROrchStatus *****", isDebugEnabled)\r
@@ -81,7 +81,7 @@ class AllottedResourceUtils {
        // get Allotted Resource by AllottedResourceId\r
        // used on Delete - called from doDeleteAR\r
        // setsVariable aaiARGetResponse\r
-       public String getARbyId (Execution execution, String allottedResourceId) {\r
+       public String getARbyId (DelegateExecution execution, String allottedResourceId) {\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " ***** getARbyId ***** ", isDebugEnabled)\r
                String arLink = getARLinkbyId(execution, allottedResourceId)\r
@@ -94,7 +94,7 @@ class AllottedResourceUtils {
                return ar;\r
        }\r
        \r
-       public String getPSIFmARLink(Execution execution, String arLink)\r
+       public String getPSIFmARLink(DelegateExecution execution, String arLink)\r
        {\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                // Path: /aai/{version}/business/customers/customer/{cust}/service-subscriptions/service-subscription/{subs}/service-instances/service-instance/{psiid}/allotted-resources/allotted-resource/{arid}\r
@@ -108,7 +108,7 @@ class AllottedResourceUtils {
 \r
        // get Allotted Resource Link by AllottedResourceId using Nodes Query\r
        // used on Delete - called from getARbyId\r
-       public String getARLinkbyId (Execution execution, String allottedResourceId) {\r
+       public String getARLinkbyId (DelegateExecution execution, String allottedResourceId) {\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " ***** getARLinkbyId ***** ", isDebugEnabled)\r
                String arLink = null\r
@@ -154,7 +154,7 @@ class AllottedResourceUtils {
        // used on Create called from getARORchStatus\r
        // used on Delete called from getARbyId\r
        // setsVariable aaiARPath - used for Patch in create\r
-       public String getARbyLink (Execution execution, String link, String role) {\r
+       public String getARbyLink (DelegateExecution execution, String link, String role) {\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " ***** getARbyLink ***** ", isDebugEnabled)\r
                String ar = null\r
@@ -237,7 +237,7 @@ class AllottedResourceUtils {
                return ar\r
        }\r
 \r
-       public void updateAROrchStatus(Execution execution, String status, String aaiARPath){\r
+       public void updateAROrchStatus(DelegateExecution execution, String status, String aaiARPath){\r
                def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " *** updaAROrchStatus *** ", isDebugEnabled)\r
                try{\r
@@ -275,7 +275,7 @@ class AllottedResourceUtils {
        }\r
        \r
        //Sets Variable "wasDeleted"\r
-       public void deleteAR(Execution execution, String aaiARPath){\r
+       public void deleteAR(DelegateExecution execution, String aaiARPath){\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " *** deleteAR *** aaiARPath:" + aaiARPath, isDebugEnabled)\r
                try {\r
@@ -315,7 +315,7 @@ class AllottedResourceUtils {
                utils.log("DEBUG", " *** Exit deleteAR *** ", isDebugEnabled)\r
        }\r
 \r
-       public void buildAAIErrorResponse(Execution execution, String response, String errorMessage){\r
+       public void buildAAIErrorResponse(DelegateExecution execution, String response, String errorMessage){\r
                def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
                utils.log("DEBUG", " *** BuildAAIErrorResponse*** ", isDebugEnabled)\r
 \r