Class RepositoryDump

java.lang.Object
com.priint.pubserver.webservice.RepositoryDump
All Implemented Interfaces:
Serializable

public class RepositoryDump extends Object implements Serializable
A repository dump format containing a list of files for export or import.
A file represents a repository entry with metadata and content. Files are identified by their full repository path.
Files can be marked for deletion. Deletions should be processed before upserts.
See Also:
  • Constructor Details

    • RepositoryDump

      public RepositoryDump()
  • Method Details

    • addFile

      public RepositoryDump addFile(String path, PluginConfig pluginConfig)
      Parameters:
      path - must not be null
      pluginConfig -
      Returns:
      RepositoryDump for method chaining. Throws a IllegalArgumentException if path is not set.
    • addFile

      public RepositoryDump addFile(String path, PluginConfig pluginConfig, RepositoryDump.PostAction postAction)
      Parameters:
      path - must not be null
      pluginConfig -
      postAction -
      Returns:
      RepositoryDump for method chaining. Throws a IllegalArgumentException if path is not set.
    • addFile

      public RepositoryDump addFile(String path, PluginConfig pluginConfig, ConfigFileProperties configFileProperties)
      Parameters:
      path - must not be null
      pluginConfig -
      configFileProperties -
      Returns:
      RepositoryDump for method chaining. Throws a IllegalArgumentException if path is not set.
    • addFile

      public RepositoryDump addFile(String path, PluginConfig pluginConfig, ConfigFileProperties configFileProperties, RepositoryDump.PostAction postAction)
      Parameters:
      path - must not be null
      pluginConfig -
      configFileProperties -
      postAction -
      Returns:
      RepositoryDump for method chaining. Throws a IllegalArgumentException if path is not set.
    • addFileForRemoval

      public RepositoryDump addFileForRemoval(String path)
      Parameters:
      path -
      Returns:
      RepositoryDump for method chaining.
    • getBasepath

      public String getBasepath()
      Returns:
      Base path for reading files from the repository or null if not set.
    • getCreated

      public String getCreated()
      Returns:
      Time stamp when the dump was produced or null if not set.
    • getDeep

      public Boolean getDeep()
      Returns:
      "true" if dump creation was recursive, i.e. dump contains all files below the basepath. If deep is "null" or "false", then only the direct files within a folder are contained in a dump.
    • getFile

      public RepositoryDump.File getFile(String path)
      Get file by its path. File path comparisons are case-sensitive.
      Parameters:
      path -
      Returns:
      file or null if not found.
    • getFiles

      public List<RepositoryDump.File> getFiles()
      Returns:
      files
    • getRequest

      public URI getRequest()
      Returns:
      Request that was executed to produce the dump or null if not set.
    • getServer

      public String getServer()
      Returns:
      Server on which the dump was produced or null if not set.
    • setBasepath

      public void setBasepath(String basepath)
      Base path for reading files from the repository.
      Parameters:
      basepath -
    • setCreated

      public void setCreated(String created)
      Time stamp when the dump was produced or null if not set.
      Parameters:
      created -
    • setDeep

      public void setDeep(Boolean deep)
      Parameters:
      deep -
    • setRequest

      public void setRequest(URI request)
      Request that was executed to produce the dump.
      Parameters:
      request -
    • setServer

      public void setServer(String server)
      Server on which the dump was produced or null if not set.
      Parameters:
      server -