3 Replies Latest reply on Jan 24, 2013 7:24 AM by Gareth Edwards

    Completing a human task with results

    Gareth Edwards Newbie



      I can complete a human task using the TaskClient  like so:


      ContentData contentData = ContentMarshallerHelper.marshal(content,  null);

              BlockingTaskOperationResponseHandler taskResponseHandler = new BlockingTaskOperationResponseHandler();


              client.complete(taskId, userId, contentData, taskResponseHandler);





      But how can I complete a task a get a result?


      The TaskClient API has two complete methods:


      complete(long taskId, String userId, ContentData outputData,TaskClientHandler.TaskOperationResponseHandler responseHandler)



      completeWithResults(long taskId, String userId, Object results,TaskClientHandler.TaskOperationResponseHandler responseHandler)


      I am using the first method as I need to pass in data on completion.

      The second method appears to return results on completion but doesn't allow for passing in of content data.

      How can I complete a human task with content data and get back a result?


      Thanks in advance,