protected Double getCollectResultValue(TypedValue collectResultValue) { // the built-in collect aggregators return only numbers if(collectResultValue instanceof IntegerValue) { return ((IntegerValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof LongValue) { return ((LongValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof DoubleValue) { return ((DoubleValue) collectResultValue).getValue(); } else { throw LOG.collectResultValueOfUnsupportedTypeException(collectResultValue); } }
protected Double getCollectResultValue(TypedValue collectResultValue) { // the built-in collect aggregators return only numbers if(collectResultValue instanceof IntegerValue) { return ((IntegerValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof LongValue) { return ((LongValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof DoubleValue) { return ((DoubleValue) collectResultValue).getValue(); } else { throw LOG.collectResultValueOfUnsupportedTypeException(collectResultValue); } }
public void writeValue(IntegerValue variableValue, ValueFields valueFields) { Integer value = variableValue.getValue(); if (value!=null) { valueFields.setLongValue(((Integer) value).longValue()); valueFields.setTextValue(value.toString()); } else { valueFields.setLongValue(null); valueFields.setTextValue(null); } }
public void writeValue(IntegerValue variableValue, ValueFields valueFields) { Integer value = variableValue.getValue(); if (value!=null) { valueFields.setLongValue(((Integer) value).longValue()); valueFields.setTextValue(value.toString()); } else { valueFields.setLongValue(null); valueFields.setTextValue(null); } }
protected Integer getLoopVariable(ActivityExecution execution, String variableName) { IntegerValue value = execution.getVariableLocalTyped(variableName); ensureNotNull("The variable \"" + variableName + "\" could not be found in execution with id " + execution.getId(), "value", value); return value.getValue(); }
protected Integer getLoopVariable(ActivityExecution execution, String variableName) { IntegerValue value = execution.getVariableLocalTyped(variableName); ensureNotNull("The variable \"" + variableName + "\" could not be found in execution with id " + execution.getId(), "value", value); return value.getValue(); }
protected Double getCollectResultValue(TypedValue collectResultValue) { // the built-in collect aggregators return only numbers if(collectResultValue instanceof IntegerValue) { return ((IntegerValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof LongValue) { return ((LongValue) collectResultValue).getValue().doubleValue(); } else if(collectResultValue instanceof DoubleValue) { return ((DoubleValue) collectResultValue).getValue(); } else { throw LOG.collectResultValueOfUnsupportedTypeException(collectResultValue); } }
public void writeValue(IntegerValue variableValue, ValueFields valueFields) { Integer value = variableValue.getValue(); if (value!=null) { valueFields.setLongValue(((Integer) value).longValue()); valueFields.setTextValue(value.toString()); } else { valueFields.setLongValue(null); valueFields.setTextValue(null); } }
protected Integer getLoopVariable(ActivityExecution execution, String variableName) { IntegerValue value = execution.getVariableLocalTyped(variableName); ensureNotNull("The variable \"" + variableName + "\" could not be found in execution with id " + execution.getId(), "value", value); return value.getValue(); }