JBoss Community

Re: Getting the current state in a process and printing out as String

created by Demian Calcaprina in jBPM - View the full discussion

With this you can get the state:

WorkflowProcessInstance pi = (WorkflowProcessInstance)ksession.getProcessInstance(pid);

 

And states are:

int STATE_PENDING   = 0;

int STATE_ACTIVE    = 1;

int STATE_COMPLETED = 2;

int STATE_ABORTED   = 3;

int STATE_SUSPENDED = 4;

 

I don't know if there is any method that makes that, but you can code it easily with this information.

 

Hope it helps,

 

Demian

Reply to this message by going to Community

Start a new discussion in jBPM at Community