Package org.activiti.engine.impl.cfg

Examples of org.activiti.engine.impl.cfg.IdGenerator


     
      // Insert historic process-instance
      getDbSqlSession().insert(historicProcessInstance);
 
      // Also record the start-event manually, as there is no "start" activity history listener for this
      IdGenerator idGenerator = Context.getProcessEngineConfiguration().getIdGenerator();
     
      String processDefinitionId = processInstance.getProcessDefinitionId();
      String processInstanceId = processInstance.getProcessInstanceId();
      String executionId = processInstance.getId();
 
      HistoricActivityInstanceEntity historicActivityInstance = new HistoricActivityInstanceEntity();
      historicActivityInstance.setId(idGenerator.getNextId());
      historicActivityInstance.setProcessDefinitionId(processDefinitionId);
      historicActivityInstance.setProcessInstanceId(processInstanceId);
      historicActivityInstance.setExecutionId(executionId);
      historicActivityInstance.setActivityId(processInstance.getActivityId());
      historicActivityInstance.setActivityName((String) processInstance.getActivity().getProperty("name"));
View Full Code Here


      if (activitiyInstance != null) {
        activitiyInstance.setCalledProcessInstanceId(subProcessInstance.getProcessInstanceId());
      }
     
      // Fix for ACT-1728: start-event not recorded for subprocesses
      IdGenerator idGenerator = Context.getProcessEngineConfiguration().getIdGenerator();
     
      // Also record the start-event manually, as there is no "start" activity history listener for this
      HistoricActivityInstanceEntity historicActivityInstance = new HistoricActivityInstanceEntity();
      historicActivityInstance.setId(idGenerator.getNextId());
      historicActivityInstance.setProcessDefinitionId(subProcessInstance.getProcessDefinitionId());
      historicActivityInstance.setProcessInstanceId(subProcessInstance.getProcessInstanceId());
      historicActivityInstance.setExecutionId(subProcessInstance.getId());
      historicActivityInstance.setActivityId(initialActivity.getId());
      historicActivityInstance.setActivityName((String) initialActivity.getProperty("name"));
View Full Code Here

*/
  @Override
public void recordActivityStart(ExecutionEntity executionEntity) {
    if(isHistoryLevelAtLeast(HistoryLevel.ACTIVITY)) {
      if(executionEntity.getActivity() != null) {
        IdGenerator idGenerator = Context.getProcessEngineConfiguration().getIdGenerator();
       
        String processDefinitionId = executionEntity.getProcessDefinitionId();
        String processInstanceId = executionEntity.getProcessInstanceId();
        String executionId = executionEntity.getId();
       
        HistoricActivityInstanceEntity historicActivityInstance = new HistoricActivityInstanceEntity();
        historicActivityInstance.setId(idGenerator.getNextId());
        historicActivityInstance.setProcessDefinitionId(processDefinitionId);
        historicActivityInstance.setProcessInstanceId(processInstanceId);
        historicActivityInstance.setExecutionId(executionId);
        historicActivityInstance.setActivityId(executionEntity.getActivityId());
        historicActivityInstance.setActivityName((String) executionEntity.getActivity().getProperty("name"));
View Full Code Here

     
      // Insert historic process-instance
      getDbSqlSession().insert(historicProcessInstance);
 
      // Also record the start-event manually, as there is no "start" activity history listener for this
      IdGenerator idGenerator = Context.getProcessEngineConfiguration().getIdGenerator();
     
      String processDefinitionId = processInstance.getProcessDefinitionId();
      String processInstanceId = processInstance.getProcessInstanceId();
      String executionId = processInstance.getId();
 
      HistoricActivityInstanceEntity historicActivityInstance = new HistoricActivityInstanceEntity();
      historicActivityInstance.setId(idGenerator.getNextId());
      historicActivityInstance.setProcessDefinitionId(processDefinitionId);
      historicActivityInstance.setProcessInstanceId(processInstanceId);
      historicActivityInstance.setExecutionId(executionId);
      historicActivityInstance.setActivityId(processInstance.getActivityId());
      historicActivityInstance.setActivityName((String) processInstance.getActivity().getProperty("name"));
View Full Code Here

  /**
   * Record the start of an activitiy, if activity history is enabled.
   */
  public void recordActivityStart(ExecutionEntity executionEntity) {
    if(isHistoryLevelAtLeast(HistoryLevel.ACTIVITY)) {
      IdGenerator idGenerator = Context.getProcessEngineConfiguration().getIdGenerator();
     
      String processDefinitionId = executionEntity.getProcessDefinitionId();
      String processInstanceId = executionEntity.getProcessInstanceId();
      String executionId = executionEntity.getId();

      HistoricActivityInstanceEntity historicActivityInstance = new HistoricActivityInstanceEntity();
      historicActivityInstance.setId(idGenerator.getNextId());
      historicActivityInstance.setProcessDefinitionId(processDefinitionId);
      historicActivityInstance.setProcessInstanceId(processInstanceId);
      historicActivityInstance.setExecutionId(executionId);
      historicActivityInstance.setActivityId(executionEntity.getActivityId());
      historicActivityInstance.setActivityName((String) executionEntity.getActivity().getProperty("name"));
View Full Code Here

TOP

Related Classes of org.activiti.engine.impl.cfg.IdGenerator

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.