Get Variable Return the Bonita Flow

1
0
-1

Dear,

I created a variable "myVariable" type Double in Bonita Studio 6.3.1.

I exported the file. "Bar" and need to know how to retrieve the value of this variable through the java API Runtime BOS 6.3.1.

 final LoginAPI loginAPI = TenantAPIAccessor.getLoginAPI();
 System.out.println("Logando como install,install");
APISession sessionAPI = loginAPI.login("install", "install");
System.out.println("Logado como install,install");
ProcessAPI processAPI = TenantAPIAccessor.getProcessAPI(sessionAPI);
System.out.println("processAPI criado");
BusinessArchive businessArchive = null;
String pathBarRepositorio = "D:\\myFile.bar";
// deploy the bar file
File fileBarTmp = new File(pathBarRepositorio);
businessArchive = BusinessArchiveFactory.readBusinessArchive(fileBarTmp);
long processDefinitionId = processAPI.getProcessDefinitionId(processDefinition.getName(), processDefinition.getVersion());
 Map<String, Serializable> variables = new HashMap<String, Serializable>();
 variables.put("varIn1", 10);
 variables.put("varIn2", 20);
ProcessInstance processInstance = processAPI.startProcess(processDefinitionId,null,variables);

//????????????????

How do I retrieve a variable output flow value in Bonita Runtime?

1 answer

1
0
-1

Hi,

I think your are looking for that method which allow you to get a process data value based on the process instance ID and the name of the process data you want: http://documentation.bonitasoft.com/javadoc/api/6.3/org/bonitasoft/engin...(java.lang.String, long)

Hope it helps,

Pierrick

Notifications