public void initIdGenerator() {
    if (idGenerator == null) {
      CommandExecutor idGeneratorCommandExecutor = null;
      if (idGeneratorDataSource != null) {
        ProcessEngineConfigurationImpl processEngineConfiguration = new StandaloneProcessEngineConfiguration();
        processEngineConfiguration.setDataSource(idGeneratorDataSource);
        processEngineConfiguration.setDatabaseSchemaUpdate(DB_SCHEMA_UPDATE_FALSE);
        processEngineConfiguration.init();
        idGeneratorCommandExecutor = processEngineConfiguration.getCommandExecutor();
      } else if (idGeneratorDataSourceJndiName != null) {
        ProcessEngineConfigurationImpl processEngineConfiguration = new StandaloneProcessEngineConfiguration();
        processEngineConfiguration.setDataSourceJndiName(idGeneratorDataSourceJndiName);
        processEngineConfiguration.setDatabaseSchemaUpdate(DB_SCHEMA_UPDATE_FALSE);
        processEngineConfiguration.init();
        idGeneratorCommandExecutor = processEngineConfiguration.getCommandExecutor();
      } else {
        idGeneratorCommandExecutor = getCommandExecutor();
      }

      DbIdGenerator dbIdGenerator = new DbIdGenerator();
      dbIdGenerator.setIdBlockSize(idBlockSize);
      dbIdGenerator.setCommandExecutor(idGeneratorCommandExecutor);
      dbIdGenerator.setCommandConfig(getDefaultCommandConfig().transactionRequiresNew());
      idGenerator = dbIdGenerator;
    }
  }
public void initIdGenerator ( ) { if ( idGenerator == null ) { CommandExecutor idGeneratorCommandExecutor = null ; if ( idGeneratorDataSource != null ) { ProcessEngineConfigurationImpl processEngineConfiguration = new StandaloneProcessEngineConfiguration ( ) ; processEngineConfiguration . setDataSource ( idGeneratorDataSource ) ; processEngineConfiguration . setDatabaseSchemaUpdate ( DB_SCHEMA_UPDATE_FALSE ) ; processEngineConfiguration . init ( ) ; idGeneratorCommandExecutor = processEngineConfiguration . getCommandExecutor ( ) ; } else if ( idGeneratorDataSourceJndiName != null ) { ProcessEngineConfigurationImpl processEngineConfiguration = new StandaloneProcessEngineConfiguration ( ) ; processEngineConfiguration . setDataSourceJndiName ( idGeneratorDataSourceJndiName ) ; processEngineConfiguration . setDatabaseSchemaUpdate ( DB_SCHEMA_UPDATE_FALSE ) ; processEngineConfiguration . init ( ) ; idGeneratorCommandExecutor = processEngineConfiguration . getCommandExecutor ( ) ; } else { idGeneratorCommandExecutor = getCommandExecutor ( ) ; } DbIdGenerator dbIdGenerator = new DbIdGenerator ( ) ; dbIdGenerator . setIdBlockSize ( idBlockSize ) ; dbIdGenerator . setCommandExecutor ( idGeneratorCommandExecutor ) ; dbIdGenerator . setCommandConfig ( getDefaultCommandConfig ( ) . transactionRequiresNew ( ) ) ; idGenerator = dbIdGenerator ; } }
/////////////////////////////////////////////////////////////