Class EntityImportMigrator


  • public final class EntityImportMigrator
    extends Object
    Helper methods for migrating old IEntityImportConfig to their corresponding new versions.
    Since:
    8.3.0
    Author:
    XIMA MEDIA GmbH
    • Method Detail

      • migrateCssTemplates

        public static EntityImportConfigMigrationResult migrateCssTemplates​(IEntityContext ec,
                                                                            Mandant client,
                                                                            IExportUnzipResult unzipResult,
                                                                            Iterable<IEntityImportConfig<?>> configs)
        Finds all Textbaustein entities of category CSS and replaces them with ClientFormTheme entities. Searches for an existing form theme config that matches the CSS template, and if none is found, creates a new transient form theme entity with the data of the CSS template.
        Parameters:
        ec - Entity context to use for accessing the database.
        client - The client that contains the CSS templates and form themes.
        unzipResult - The unzip result of the import file.
        configs - A list of import configs to migrate. The list will be modified in place.
        Returns:
        The result of the migration, containing the new import configs to add and the old configs to remove.