Class DefaultMigrationInstructionGenerator
java.lang.Object
org.camunda.bpm.engine.impl.migration.DefaultMigrationInstructionGenerator
- All Implemented Interfaces:
MigrationInstructionGenerator
public class DefaultMigrationInstructionGenerator
extends Object
implements MigrationInstructionGenerator
- Author:
- Thorben Lindhauer
-
Field Summary
Modifier and TypeFieldDescriptionprotected MigrationActivityMatcher
protected List<MigrationActivityValidator>
protected List<MigrationInstructionValidator>
-
Constructor Summary
ConstructorDescriptionDefaultMigrationInstructionGenerator
(MigrationActivityMatcher migrationActivityMatcher) -
Method Summary
Modifier and TypeMethodDescriptiongenerate
(ProcessDefinitionImpl sourceProcessDefinition, ProcessDefinitionImpl targetProcessDefinition, boolean updateEventTriggers) Generate all migration instructions for mapped activities between two process definitions.void
generate
(ScopeImpl sourceScope, ScopeImpl targetScope, ProcessDefinitionImpl sourceProcessDefinition, ProcessDefinitionImpl targetProcessDefinition, ValidatingMigrationInstructions existingInstructions, boolean updateEventTriggers) protected List<ValidatingMigrationInstruction>
generateInstructionsForActivities
(Collection<ActivityImpl> sourceActivities, Collection<ActivityImpl> targetActivities, boolean updateEventTriggers, ValidatingMigrationInstructions existingInstructions) protected boolean
isValidActivity
(ActivityImpl activity) migrationActivityValidators
(List<MigrationActivityValidator> migrationActivityValidators) Sets the list of migration activity validators which validate that a activity is a candidate for the migration.migrationInstructionValidators
(List<MigrationInstructionValidator> migrationInstructionValidators) Sets the list of migration instruction validators currently used by the process engine.
-
Field Details
-
migrationActivityValidators
-
migrationInstructionValidators
-
migrationActivityMatcher
-
-
Constructor Details
-
DefaultMigrationInstructionGenerator
-
-
Method Details
-
migrationActivityValidators
public MigrationInstructionGenerator migrationActivityValidators(List<MigrationActivityValidator> migrationActivityValidators) Description copied from interface:MigrationInstructionGenerator
Sets the list of migration activity validators which validate that a activity is a candidate for the migration.- Specified by:
migrationActivityValidators
in interfaceMigrationInstructionGenerator
- Parameters:
migrationActivityValidators
- the list of validators to check- Returns:
- this generator instance
-
migrationInstructionValidators
public MigrationInstructionGenerator migrationInstructionValidators(List<MigrationInstructionValidator> migrationInstructionValidators) Description copied from interface:MigrationInstructionGenerator
Sets the list of migration instruction validators currently used by the process engine. Implementations may use these to restrict the search space.- Specified by:
migrationInstructionValidators
in interfaceMigrationInstructionGenerator
- Returns:
- this
-
generate
public ValidatingMigrationInstructions generate(ProcessDefinitionImpl sourceProcessDefinition, ProcessDefinitionImpl targetProcessDefinition, boolean updateEventTriggers) Description copied from interface:MigrationInstructionGenerator
Generate all migration instructions for mapped activities between two process definitions. A activity can be mapped if theMigrationActivityMatcher
matches it with an activity from the target process definition.- Specified by:
generate
in interfaceMigrationInstructionGenerator
- Parameters:
sourceProcessDefinition
- the source process definitiontargetProcessDefinition
- the target process definiton- Returns:
- the list of generated instructions
-
generateInstructionsForActivities
protected List<ValidatingMigrationInstruction> generateInstructionsForActivities(Collection<ActivityImpl> sourceActivities, Collection<ActivityImpl> targetActivities, boolean updateEventTriggers, ValidatingMigrationInstructions existingInstructions) -
generate
public void generate(ScopeImpl sourceScope, ScopeImpl targetScope, ProcessDefinitionImpl sourceProcessDefinition, ProcessDefinitionImpl targetProcessDefinition, ValidatingMigrationInstructions existingInstructions, boolean updateEventTriggers) -
isValidActivity
-