use of org.wso2.carbon.bpel.stub.mgt.types.Category_type1 in project carbon-business-process by wso2.
the class BpelUIUtil method updateBackEnd.
public static void updateBackEnd(ProcessManagementServiceClient processMgtClient, ProcessDeployDetailsList_type0 processDeployDetailsListType, DeploymentDescriptorUpdater deployDescriptorUpdater, String[] selecttype, List<String> scopeNames) throws Exception {
updateScopeEvents(selecttype, scopeNames, deployDescriptorUpdater);
ProcessStatus processStatus = ProcessStatus.Factory.fromValue(deployDescriptorUpdater.getProcessstate().toUpperCase());
processDeployDetailsListType.setProcessState(processStatus);
processDeployDetailsListType.setIsInMemory(Boolean.parseBoolean(deployDescriptorUpdater.getInmemorystatus()));
ProcessEventsListType processEventsListType = new ProcessEventsListType();
EnableEventListType enableEventListType = new EnableEventListType();
ScopeEventListType scopeEventListType = new ScopeEventListType();
enableEventListType.setEnableEvent(deployDescriptorUpdater.getEvents());
scopeEventListType.setScopeEvent(deployDescriptorUpdater.getScopeEvents());
processEventsListType.setEnableEventsList(enableEventListType);
processEventsListType.setScopeEventsList(scopeEventListType);
if (!deployDescriptorUpdater.getGentype().equalsIgnoreCase("selected")) {
Generate_type1 generate = Generate_type1.Factory.fromValue(deployDescriptorUpdater.getGentype());
processEventsListType.setGenerate(generate);
}
processDeployDetailsListType.setProcessEventsList(processEventsListType);
CleanUpListType cleanUpList = new CleanUpListType();
CleanUpType successCleanUpType = new CleanUpType();
On_type1 successOn = On_type1.success;
successCleanUpType.setOn(successOn);
CategoryListType successCategoryList = new CategoryListType();
String[] sCategories = deployDescriptorUpdater.getSuccesstypecleanups();
if (sCategories != null) {
for (String categoryName : sCategories) {
Category_type1 categoryType1 = Category_type1.Factory.fromValue(categoryName);
successCategoryList.addCategory(categoryType1);
}
}
successCleanUpType.setCategoryList(successCategoryList);
cleanUpList.addCleanUp(successCleanUpType);
CleanUpType failureCleanUpType = new CleanUpType();
On_type1 failureOn = On_type1.failure;
failureCleanUpType.setOn(failureOn);
CategoryListType failureCategoryList = new CategoryListType();
String[] fCategories = deployDescriptorUpdater.getFailuretypecleanups();
if (fCategories != null) {
for (String categoryName : fCategories) {
Category_type1 categoryType1 = Category_type1.Factory.fromValue(categoryName);
failureCategoryList.addCategory(categoryType1);
}
}
failureCleanUpType.setCategoryList(failureCategoryList);
cleanUpList.addCleanUp(failureCleanUpType);
processDeployDetailsListType.setCleanUpList(cleanUpList);
processMgtClient.updateDeployInfo(processDeployDetailsListType);
}
use of org.wso2.carbon.bpel.stub.mgt.types.Category_type1 in project carbon-business-process by wso2.
the class BPELPackageRepositoryUtils method getSuccessCleanUpType.
public static CleanUpType getSuccessCleanUpType(String successCleanupsInString) {
CleanUpType successCleanUp = new CleanUpType();
String[] successCategories = getStringsFromArray(successCleanupsInString);
CategoryListType categoryList = new CategoryListType();
for (String category : successCategories) {
Category_type1 categoryType1 = Category_type1.Factory.fromValue(category.toLowerCase());
categoryList.addCategory(categoryType1);
}
successCleanUp.setOn(On_type1.success);
successCleanUp.setCategoryList(categoryList);
return successCleanUp;
}
Aggregations