ReflectionUtils.doWithMethods(targetClass,
new ReflectionUtils.MethodCallback() {
@SuppressWarnings("unchecked")
public void doWith(Method method) throws IllegalArgumentException, IllegalAccessException {
State state = AnnotationUtils.getAnnotation(method, State.class);
String processName = component.processKey();
if (StringUtils.hasText(state.process())) {
processName = state.process();
}
String stateName = state.state();
if (!StringUtils.hasText(stateName)) {
stateName = state.value();
}
Assert.notNull(stateName, "You must provide a stateName!");
Map<Integer, String> vars = new HashMap<Integer, String>();