Map<ProcessDefinition, MigrationDescriptor> migrations = (Map<ProcessDefinition, MigrationDescriptor>)parse.contextMapGet(Parse.CONTEXT_KEY_MIGRATIONS);
if (migrations == null) {
migrations = new HashMap<ProcessDefinition, MigrationDescriptor>();
parse.contextMapPut(Parse.CONTEXT_KEY_MIGRATIONS, migrations);
}
MigrationDescriptor migrationDescriptor = new MigrationDescriptor();
String action = migrationElement.getAttribute("action");
if ("end".equals(action)) {
migrationDescriptor.addMigrationHandlerClassName(AbortMigrationHandler.class.getName());
}
parseMigrationHandlers(migrationElement, migrationDescriptor);
if (!"end".equals(action)) {
migrationDescriptor.addMigrationHandlerClassName(DefaultMigrationHandler.class.getName());
parseActivityMappings(migrationElement, migrationDescriptor);
}
String versions = migrationElement.getAttribute("versions");
if (versions != null && !"".equals(versions)) {
addVersionInformation(versions, migrationDescriptor);