Package org.uengine.kernel

Examples of org.uengine.kernel.EndActivity


  }
 
  public void processStop(ProcessStopMsg psMsg) throws Exception {
    ProcessInstance instance = pm.getProcessInstance(psMsg.getInstanceId());
   
    EndActivity endActivity = new EndActivity();
    endActivity.setEscalate(true);
   
    String instanceStatus = psMsg.getInstanceStatus();
    if (ProcessStopMsg.INSTANCE_STATUS_CANCELLED.equalsIgnoreCase(instanceStatus)) {
      endActivity.setStatus(EndActivity.STATUS_CANCELLED);
     
    } else if (ProcessStopMsg.INSTANCE_STATUS_COMPLETED.equalsIgnoreCase(instanceStatus)) {
      endActivity.setStatus(EndActivity.STATUS_COMPLETED);
     
    } else if (ProcessStopMsg.INSTANCE_STATUS_FAULT.equalsIgnoreCase(instanceStatus)) {
      endActivity.setStatus(EndActivity.STATUS_FAULT);
     
    } else if (ProcessStopMsg.INSTANCE_STATUS_STOPPED.equalsIgnoreCase(instanceStatus)) {
      endActivity.setStatus(EndActivity.STATUS_STOPPED);
     
    } else {
      endActivity.setStatus(EndActivity.STATUS_COMPLETED);
    }
   
    endActivity.executeActivity(instance);
  }
View Full Code Here

TOP

Related Classes of org.uengine.kernel.EndActivity

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.