private void writeAction(Element parentElement, Action action) { String actionName = ActionTypes.getActionName(action.getClass()); Element actionElement = parentElement.addElement(actionName); if (action.getName() != null) { actionElement.addAttribute("name", action.getName()); } if (!action.acceptsPropagatedEvents()) { actionElement.addAttribute("accept-propagated-events", "false"); } action.write(actionElement); }
private void writeAction(Element parentElement, Action action) { String actionName = ActionTypes.getActionName(action.getClass()); Element actionElement = parentElement.addElement(actionName); if (action.getName() != null) { actionElement.addAttribute("name", action.getName()); } if (!action.acceptsPropagatedEvents()) { actionElement.addAttribute("accept-propagated-events", "false"); } action.write(actionElement); }
private void executeActions(List actions, ExecutionContext executionContext, boolean isPropagated) { if (actions == null) return; for (Iterator iter = actions.iterator(); iter.hasNext();) { Action action = (Action) iter.next(); if (!action.acceptsPropagatedEvents() && isPropagated) continue; if (action.isAsync()) { ExecuteActionJob job = createAsyncActionExecutionJob(executionContext.getToken(), action); MessageService messageService = executionContext.getJbpmContext() .getServices() .getMessageService(); messageService.send(job); } else { executeAction(action, executionContext); } } }
private void executeActions(List actions, ExecutionContext executionContext, boolean isPropagated) { if (actions == null) return; for (Iterator iter = actions.iterator(); iter.hasNext();) { Action action = (Action) iter.next(); if (!action.acceptsPropagatedEvents() && isPropagated) continue; if (action.isAsync()) { ExecuteActionJob job = createAsyncActionExecutionJob(executionContext.getToken(), action); MessageService messageService = executionContext.getJbpmContext() .getServices() .getMessageService(); messageService.send(job); } else { executeAction(action, executionContext); } } }