Różnice

Różnice między wybraną wersją a wersją aktualną.

Odnośnik do tego porównania

Both sides previous revision Poprzednia wersja
Nowa wersja
Poprzednia wersja
Nowa wersja Both sides next revision
pl:dydaktyka:dss:lab2 [2017/10/16 15:48]
kkluza [Testing the model]
pl:dydaktyka:dss:lab2 [2017/10/16 16:04]
kkluza [Extending the test]
Linia 54: Linia 54:
 </​code>​ </​code>​
  
 +===== Extending the test =====
  
  
 +Using the interface available through ''​ TaskService ''​ and ''​ FormService '',​ test the model from the previous classes (as below, if not timed) for two scenarios (selecting each of the XOR gateways).
  
 +{{:​pl:​dydaktyka:​bim:​lab2:​process5-eclipse-example.png?​800|}}
  
 +Useful snippets of code:
 +
 +  * user authentication (in this case: kermit):
 +<code java>
 +identityService.setAuthenticatedUserId("​kermit"​);​
 +</​code> ​
 +  * interface for downloading a task list for a specific user:
 +<code java>
 +List<​Task>​ taskList = taskService.createTaskQuery().processInstanceId(arg0).taskAssignee(arg0).list()
 +</​code>​
 +  * if the task is successfully completed, we can call:
 +<​code>​
 +taskService.complete(arg0);​
 +</​code>​
 +  * interface for viewing the forms:
 +<code java>
 +FormService formService = processEngine.getFormService();​
 +TaskFormData taskFormData = formService.getTaskFormData(taskList.get(0).getId());​
 +List<​FormProperty>​ formList = taskFormData.getFormProperties();​
 +</​code>​
 +
 +For more information check [[http://​activiti.org/​javadocs/​|Activiti API]].
 +
 +===== Executing the process =====
  
pl/dydaktyka/dss/lab2.txt · ostatnio zmienione: 2019/06/27 15:50 (edycja zewnętrzna)
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0