Class WizardMigrator


  • public class WizardMigrator
    extends Object
    • Constructor Detail

      • WizardMigrator

        public WizardMigrator()
    • Method Detail

      • migrateLabels

        protected org.bidib.jbidibc.core.schema.bidiblabels.NodeLabels migrateLabels​(ApplicationContext context,
                                                                                     Class<?> migratorClass,
                                                                                     long uniqueId,
                                                                                     String... searchpaths)
        Migrate the labels.

        The new (bidib2) labels are stored in the labels subfolder, e.g. <user.home>\.bidib\labels. The older labels are stored under <user.home>\.BiDiBWizard or at a customized location.

        Parameters:
        context - the migration context
        uniqueId - the uniqueId of the node
        searchpath - the search path. The provided paths are the root path of the locations of the labels, e.g. <user.home>\.bidib or <user.home>\.BiDiBWizard.
        Returns:
        the node labels
      • findAllNodesInWizardLabels

        public Nodes findAllNodesInWizardLabels​(Class<?>[] migratorClassHolder,
                                                String... searchpaths)
        Find all nodes in wizard labels.
        Parameters:
        searchpath - the search path
        Returns:
        the node labels with all nodes
      • checkAndPerformMigration

        public String checkAndPerformMigration​(String targetPath,
                                               File migrationLogFile,
                                               String... searchRoots)
        Check if migration is required and perform the migration is necessary.
        Parameters:
        targetPath - the target path were the migration file s are stored
        searchRoots - the search roots
        migrationLogFile - the migration log file
      • executeMigrationTask

        protected void executeMigrationTask​(String targetPath,
                                            org.bidib.wizard.migration.migrator.WizardMigrator.MigrationTaskType migrationTask,
                                            File migrationLogFile,
                                            String... searchRoots)
      • getMigrationLogfile

        public File getMigrationLogfile​(String path)