private void increaseExecuteCount(WorkflowContext context) { String currentTaskName = context.getCurrentTaskName(); Integer executeCount = (Integer) context.getParameter(currentTaskName); if (executeCount == null) { context.setParameter(currentTaskName, new Integer(1)); } else { context.setParameter(currentTaskName, new Integer(executeCount.intValue() + 1)); } }
@Override public void execute(WorkflowContext context) { context.setParameter("data", context.getParameter("data").toString().toUpperCase()); increaseExecuteCount(context); }