JBoss Community

In jbpm 4.3, how to get the incoming node name in the next node?

reply from HuiSheng Xu in jBPM - View the full discussion

Hi Tun,

 

You have to cast execution to ExecutionImpl.  Then get the current activity of this execution.  Something like this:

 

 

ExecutionImpl executionImpl = (ExecutionImpl) execution;
 
Activity activity = executionImpl.getActivity();
 
List<? extends Transition> incomingTransitions = activity.getIncomingTransitions();
 
for (Transition transition : incomingTransitions) {
 
  Activity incomingActivity = transition.getSource();
 
  // here is the name of incomging activity
}

Reply to this message by going to Community

Start a new discussion in jBPM at Community