Package com.starflow.wf.engine

Examples of com.starflow.wf.engine.ProcessEngineException


  public void startProcess(long processInstId) {
    final ProcessInstance processInstance = procInstRep.findProcessInstance(processInstId);
   
    //检查流程是否处于启动状态
    if(StarFlowState.PROCESS_INST_START != processInstance.getCurrentState())
      throw new ProcessEngineException("流程实例【"+processInstId+"】未处于启动状态,不能启动流程,当前状态为:" + processInstance.getCurrentState());

    transactionTemplate.execute(new TransactionCallbackWithoutResult() {
     
      @Override
      protected void doInTransactionWithoutResult(TransactionStatus status) {
View Full Code Here


        participants = action.createWorkItemParticipants(cloneProcessInstance);
      } else {
        //反射调用bean指定的方法。
        String methodName = beanName.substring(index + 1);
        if("".equals(beanName))
          throw new ProcessEngineException("IParticipantService 实现类Bean:"+beanName+",没有指定方法名称");
       
        beanName = beanName.substring(0, index);
        try {
          Method method = action.getClass().getMethod(methodName, long.class, long.class);
          participants = (List<Participant>)method.invoke(action, cloneProcessInstance);
        } catch (Exception e) {
          throw new ProcessEngineException("IParticipantService 实现类Bean:"+beanName+",没有此方法", e);
        }
      }
    } catch (Exception e) {
      throw new ProcessEngineException("通过业务逻辑获取参与者失败", e);
    }
   
    return participants;
  }
View Full Code Here

TOP

Related Classes of com.starflow.wf.engine.ProcessEngineException

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.