Class FormBackupHelper


  • public final class FormBackupHelper
    extends Object
    Utilities for saving and loading form backups.
    Since:
    7.0.0
    Author:
    XIMA MEDIA GmbH
    • Constructor Detail

      • FormBackupHelper

        public FormBackupHelper()
    • Method Detail

      • createLocalBackupStreamedContent

        public static org.primefaces.model.StreamedContent createLocalBackupStreamedContent​(javax.servlet.http.HttpServletRequest req,
                                                                                            IXFormRenderConfig xFormConfig,
                                                                                            long projectId,
                                                                                            DownloadLocalBackupParams params)
        Creates the export download file for saving a local export of the form.
        Parameters:
        req - Currently active HTTP request.
        xFormConfig - Form render config to use for rendering the form.
        projectId - Project ID of the project to export.
        params - Params from the HTTP request.
        Returns:
        The streamed content with the local form export
      • readFormVersionBackupPersist

        public static String readFormVersionBackupPersist​(Projekt project,
                                                          long formVersionId)
        Parameters:
        project - Current project being edited.
        formVersionId - Form version ID to read.
        Returns:
        The contents of form version backup with the given ID.
      • readFormVersionPersist

        public static String readFormVersionPersist​(Projekt project,
                                                    long formVersionId)
        Parameters:
        project - Current project being edited.
        formVersionId - Form version ID to read.
        Returns:
        The contents of the form version the given ID.