[jboss-user] [jBPM] - Re: How to get an object like kcontext to call setVariable("variable", value) for begin used by following tasks??

Demian Calcaprina do-not-reply at jboss.com
Mon Oct 17 22:17:54 EDT 2011


Demian Calcaprina [http://community.jboss.org/people/calca] created the discussion

"Re: How to get an object like kcontext to call setVariable("variable",value) for begin used by following tasks??"

To view the discussion, visit: http://community.jboss.org/message/632170#632170

--------------------------------------------------------------
Hey,

As well as you use parameter mapping, you have to use result mapping.

You will have to define for example "price" (1) variable in process.. when completing the work item, you pass a map<String, Object> with results of the work item. You will have to create the map, and put a variable "price"(or the name you want) (2), can pass the map to completeWorkItem method. Into the process, you have to map the result variable to the process variable. After  executing the task, jbpm will copy the value of the result variable to the process instance variable.

And the same will apply to the subprocess. Into the parent process, you define how to map variables between process/subprocess.

Regards,

demian
--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/632170#632170]

Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20111017/adc0d1a0/attachment.html 


More information about the jboss-user mailing list