public Object getValue(VariableScope variableScope, BaseDelegateExecution contextExecution) { return getValue(variableScope); }
public Object defaultManualActivation() { Expression expression = new FixedValue(true); CaseControlRuleImpl caseControlRule = new CaseControlRuleImpl(expression); return caseControlRule; }
protected void validateFieldDeclarationsForShell(Element serviceTaskElement, List<FieldDeclaration> fieldDeclarations) { boolean shellCommandDefined = false; for (FieldDeclaration fieldDeclaration : fieldDeclarations) { String fieldName = fieldDeclaration.getName(); FixedValue fieldFixedValue = (FixedValue) fieldDeclaration.getValue(); String fieldValue = fieldFixedValue.getExpressionText(); shellCommandDefined |= fieldName.equals("command"); if ((fieldName.equals("wait") || fieldName.equals("redirectError") || fieldName.equals("cleanEnv")) && !fieldValue.toLowerCase().equals(TRUE) && !fieldValue.toLowerCase().equals("false")) { addError("undefined value for shell " + fieldName + " parameter :" + fieldValue.toString(), serviceTaskElement); } } if (!shellCommandDefined) { addError("No shell command is defined on the shell activity", serviceTaskElement); } }
public Object defaultManualActivation() { Expression expression = new FixedValue(true); CaseControlRuleImpl caseControlRule = new CaseControlRuleImpl(expression); return caseControlRule; }
public Object getValue(VariableScope variableScope, BaseDelegateExecution contextExecution) { return getValue(variableScope); }
protected void validateFieldDeclarationsForShell(Element serviceTaskElement, List<FieldDeclaration> fieldDeclarations) { boolean shellCommandDefined = false; for (FieldDeclaration fieldDeclaration : fieldDeclarations) { String fieldName = fieldDeclaration.getName(); FixedValue fieldFixedValue = (FixedValue) fieldDeclaration.getValue(); String fieldValue = fieldFixedValue.getExpressionText(); shellCommandDefined |= fieldName.equals("command"); if ((fieldName.equals("wait") || fieldName.equals("redirectError") || fieldName.equals("cleanEnv")) && !fieldValue.toLowerCase().equals(TRUE) && !fieldValue.toLowerCase().equals("false")) { addError("undefined value for shell " + fieldName + " parameter :" + fieldValue.toString(), serviceTaskElement); } } if (!shellCommandDefined) { addError("No shell command is defined on the shell activity", serviceTaskElement); } }
protected FieldDeclaration parseStringFieldDeclaration(Element fieldDeclarationElement, Element serviceTaskElement, String fieldName) { try { String fieldValue = getStringValueFromAttributeOrElement("stringValue", "string", fieldDeclarationElement); if (fieldValue != null) { return new FieldDeclaration(fieldName, Expression.class.getName(), new FixedValue(fieldValue)); } } catch (ProcessEngineException ae) { if (ae.getMessage().contains("multiple elements with tag name")) { addError("Multiple string field declarations found", serviceTaskElement); } else { addError("Error when paring field declarations: " + ae.getMessage(), serviceTaskElement); } } return null; }
public Object getValue(VariableScope variableScope, BaseDelegateExecution contextExecution) { return getValue(variableScope); }
protected void validateFieldDeclarationsForShell(Element serviceTaskElement, List<FieldDeclaration> fieldDeclarations) { boolean shellCommandDefined = false; for (FieldDeclaration fieldDeclaration : fieldDeclarations) { String fieldName = fieldDeclaration.getName(); FixedValue fieldFixedValue = (FixedValue) fieldDeclaration.getValue(); String fieldValue = fieldFixedValue.getExpressionText(); shellCommandDefined |= fieldName.equals("command"); if ((fieldName.equals("wait") || fieldName.equals("redirectError") || fieldName.equals("cleanEnv")) && !fieldValue.toLowerCase().equals(TRUE) && !fieldValue.toLowerCase().equals("false")) { addError("undefined value for shell " + fieldName + " parameter :" + fieldValue.toString(), serviceTaskElement); } } if (!shellCommandDefined) { addError("No shell command is defined on the shell activity", serviceTaskElement); } }
protected FieldDeclaration parseStringFieldDeclaration(Element fieldDeclarationElement, Element serviceTaskElement, String fieldName) { try { String fieldValue = getStringValueFromAttributeOrElement("stringValue", "string", fieldDeclarationElement); if (fieldValue != null) { return new FieldDeclaration(fieldName, Expression.class.getName(), new FixedValue(fieldValue)); } } catch (ProcessEngineException ae) { if (ae.getMessage().contains("multiple elements with tag name")) { addError("Multiple string field declarations found", serviceTaskElement); } else { addError("Error when paring field declarations: " + ae.getMessage(), serviceTaskElement); } } return null; }
public void notify(DelegateExecution execution) throws Exception { ExecutionEntity executionCasted = ((ExecutionEntity)execution); String parameterValue = null; if (parameter != null) { parameterValue = (String)parameter.getValue(execution); } String activityName = null; if (executionCasted.getActivity() != null) { activityName = executionCasted.getActivity().getProperties().get(new PropertyKey<String>("name")); } recordedEvents.add( new RecordedEvent( executionCasted.getActivityId(), activityName, execution.getEventName(), parameterValue, execution.getActivityInstanceId(), execution.getCurrentTransitionId(), execution.isCanceled(), execution.getId())); }
public Object defaultManualActivation() { Expression expression = new FixedValue(true); CaseControlRuleImpl caseControlRule = new CaseControlRuleImpl(expression); return caseControlRule; }
@Override public void execute(DelegateExecution context) throws Exception { String traceId = context.getProcessBusinessKey(); String eventNameString = null; if (eventName!=null && eventName.getValue(context)!=null) { eventNameString = (String) eventName.getValue(context); } else { // if not configured we use the element id from the flow definition as default eventNameString = context.getCurrentActivityId(); } messageSender.send(new Message<String>( // eventNameString, // traceId, // null)); // no payload at the moment }
protected FixedValue getFixedValue(CamundaField field) { CamundaString strg = field.getCamundaString(); String value = null; if (strg != null) { value = strg.getTextContent(); } if (value == null) { value = field.getCamundaStringValue(); } if (value != null) { return new FixedValue(value); } return null; }
public void notify(DelegateExecution execution) throws Exception { ExecutionEntity executionCasted = ((ExecutionEntity)execution); String parameterValue = null; if (parameter != null) { parameterValue = (String)parameter.getValue(execution); } String activityName = null; if (executionCasted.getActivity() != null) { activityName = executionCasted.getActivity().getProperties().get(new PropertyKey<String>("name")); } recordedEvents.add( new RecordedEvent( executionCasted.getActivityId(), activityName, execution.getEventName(), parameterValue, execution.getActivityInstanceId(), execution.getCurrentTransitionId(), execution.isCanceled(), execution.getId())); }
protected FixedValue getFixedValue(CamundaField field) { CamundaString strg = field.getCamundaString(); String value = null; if (strg != null) { value = strg.getTextContent(); } if (value == null) { value = field.getCamundaStringValue(); } if (value != null) { return new FixedValue(value); } return null; }
public Object defaultManualActivation() { Expression expression = new FixedValue(true); CaseControlRuleImpl caseControlRule = new CaseControlRuleImpl(expression); return caseControlRule; }
protected FieldDeclaration parseStringFieldDeclaration(Element fieldDeclarationElement, Element serviceTaskElement, String fieldName) { try { String fieldValue = getStringValueFromAttributeOrElement("stringValue", "string", fieldDeclarationElement); if (fieldValue != null) { return new FieldDeclaration(fieldName, Expression.class.getName(), new FixedValue(fieldValue)); } } catch (ProcessEngineException ae) { if (ae.getMessage().contains("multiple elements with tag name")) { addError("Multiple string field declarations found", serviceTaskElement); } else { addError("Error when paring field declarations: " + ae.getMessage(), serviceTaskElement); } } return null; }
public Object defaultManualActivation() { Expression expression = new FixedValue(true); CaseControlRuleImpl caseControlRule = new CaseControlRuleImpl(expression); return caseControlRule; }
protected FixedValue getFixedValue(CamundaField field) { CamundaString strg = field.getCamundaString(); String value = null; if (strg != null) { value = strg.getTextContent(); } if (value == null) { value = field.getCamundaStringValue(); } if (value != null) { return new FixedValue(value); } return null; }