void preprocessParameterCommand(Object cmdObj, List<Object> extraClassInstanceList) {
   if (cmdObj instanceof CompleteWorkItemCommand) {
     addPossiblyNullObject(((CompleteWorkItemCommand) cmdObj).getResult(), extraClassInstanceList);
   } else if (cmdObj instanceof SignalEventCommand) {
     addPossiblyNullObject(((SignalEventCommand) cmdObj).getEvent(), extraClassInstanceList);
   } else if (cmdObj instanceof StartCorrelatedProcessCommand) {
     StartCorrelatedProcessCommand cmd = (StartCorrelatedProcessCommand) cmdObj;
     if (cmd.getData() != null) {
       addPossiblyNullObject(cmd.getData().getDatas(), extraClassInstanceList);
     }
     addPossiblyNullObject(cmd.getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof StartProcessCommand) {
     StartProcessCommand startProcCmd = (StartProcessCommand) cmdObj;
     if (startProcCmd.getData() != null) {
       addPossiblyNullObject(startProcCmd.getData().getDatas(), extraClassInstanceList);
     }
     addPossiblyNullObject(((StartProcessCommand) cmdObj).getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof SetGlobalCommand) {
     addPossiblyNullObject(((SetGlobalCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof InsertObjectCommand) {
     addPossiblyNullObject(((InsertObjectCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof UpdateCommand) {
     addPossiblyNullObject(((UpdateCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof AddTaskCommand) {
     addPossiblyNullObject(((AddTaskCommand) cmdObj).getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof CompleteTaskCommand) {
     addPossiblyNullObject(((CompleteTaskCommand) cmdObj).getData(), extraClassInstanceList);
   } else if (cmdObj instanceof FailTaskCommand) {
     addPossiblyNullObject(((FailTaskCommand) cmdObj).getData(), extraClassInstanceList);
   }
 }
コード例 #2
0
 void preprocessParameterCommand(Object cmdObj, List<Object> extraClassInstanceList) {
   if (cmdObj instanceof CompleteWorkItemCommand) {
     addPossiblyNullObject(((CompleteWorkItemCommand) cmdObj).getResult(), extraClassInstanceList);
   } else if (cmdObj instanceof SignalEventCommand) {
     addPossiblyNullObject(((SignalEventCommand) cmdObj).getEvent(), extraClassInstanceList);
   } else if (cmdObj instanceof StartCorrelatedProcessCommand) {
     StartCorrelatedProcessCommand cmd = (StartCorrelatedProcessCommand) cmdObj;
     if (cmd.getData() != null) {
       addPossiblyNullObject(cmd.getData().getDatas(), extraClassInstanceList);
     }
     addPossiblyNullObject(cmd.getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof StartProcessCommand) {
     StartProcessCommand startProcCmd = (StartProcessCommand) cmdObj;
     if (startProcCmd.getData() != null) {
       addPossiblyNullObject(startProcCmd.getData().getDatas(), extraClassInstanceList);
     }
     addPossiblyNullObject(((StartProcessCommand) cmdObj).getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof SetGlobalCommand) {
     addPossiblyNullObject(((SetGlobalCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof InsertObjectCommand) {
     addPossiblyNullObject(((InsertObjectCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof UpdateCommand) {
     addPossiblyNullObject(((UpdateCommand) cmdObj).getObject(), extraClassInstanceList);
   } else if (cmdObj instanceof AddTaskCommand) {
     addPossiblyNullObject(((AddTaskCommand) cmdObj).getParameter(), extraClassInstanceList);
   } else if (cmdObj instanceof CompleteTaskCommand) {
     addPossiblyNullObject(((CompleteTaskCommand) cmdObj).getData(), extraClassInstanceList);
   } else if (cmdObj instanceof FailTaskCommand) {
     addPossiblyNullObject(((FailTaskCommand) cmdObj).getData(), extraClassInstanceList);
   } else if (cmdObj instanceof AddContentFromUserCommand) {
     addPossiblyNullObject(
         ((AddContentFromUserCommand) cmdObj).getOutputContentMap(), extraClassInstanceList);
   } else if (cmdObj instanceof AddContentCommand) {
     AddContentCommand cmd = (AddContentCommand) cmdObj;
     addPossiblyNullObject(cmd.getParameter(), extraClassInstanceList);
     Content jaxbContent = cmd.getJaxbContent();
     if (jaxbContent != null) {
       addPossiblyNullObject(jaxbContent.getContentMap(), extraClassInstanceList);
     }
   } else if (cmdObj instanceof SetTaskPropertyCommand) {
     addPossiblyNullObject(((SetTaskPropertyCommand) cmdObj).getOutput(), extraClassInstanceList);
   } else if (cmdObj instanceof ExecuteTaskRulesCommand) {
     addPossiblyNullObject(((ExecuteTaskRulesCommand) cmdObj).getData(), extraClassInstanceList);
   } else if (cmdObj instanceof ProcessSubTaskCommand) {
     addPossiblyNullObject(((ProcessSubTaskCommand) cmdObj).getData(), extraClassInstanceList);
   } else if (cmdObj instanceof SetProcessInstanceVariablesCommand) {
     addPossiblyNullObject(
         ((SetProcessInstanceVariablesCommand) cmdObj).getVariables(), extraClassInstanceList);
   }
 }