2 Replies Latest reply on Feb 1, 2013 7:41 AM by swiderski.maciej

    JBPM5.4 Human Task

    hyljwy

      hey friends,

           I used jbpm5.4 to run human task, my code is:

      code

      boolean isDetectionPassed =false;

      Map<String, Object> data = new HashMap<String, Object>();

      data.put("detection", isDetectionPassed);

      ... ...

       

      ContentData contentData = null;

                          if (data != null) {

                                    ByteArrayOutputStream bos = new ByteArrayOutputStream();

                                    ObjectOutputStream out;

                                    try {

                                              out = new ObjectOutputStream(bos);

                                              out.writeObject(data);

                                              out.close();

                                              contentData = new ContentData();

                                              contentData.setContent(bos.toByteArray());

                                              contentData.setAccessType(AccessType.Inline);

                                    } catch (IOException e) {

                                              e.printStackTrace();

                                    }

                          }

       

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

      then, I occurred the  problem:

      console
      java.lang.Boolean cannot be cast to org.jbpm.task.utils.MarshalledContentWrapper

       

      I don't know why, can anybody help me?