Class FileSystemOcflStorageBuilder


  • public class FileSystemOcflStorageBuilder
    extends Object
    Builder for constructing FileSystemOcflStorage objects. It is configured with sensible defaults and can minimally be used as FileSystemOcflStorage.builder().repositoryRoot(repoRoot).build()
    • Constructor Detail

      • FileSystemOcflStorageBuilder

        public FileSystemOcflStorageBuilder()
    • Method Detail

      • repositoryRoot

        public FileSystemOcflStorageBuilder repositoryRoot​(Path repositoryRoot)
        Sets the path to the OCFL repository root directory. Required.
        Parameters:
        repositoryRoot - the path to the OCFL storage root
        Returns:
        builder
      • objectMapper

        public FileSystemOcflStorageBuilder objectMapper​(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
        Overrides the default ObjectMapper that's used to serialize ocfl_layout.json
        Parameters:
        objectMapper - object mapper
        Returns:
        builder
      • verifyInventoryDigest

        public FileSystemOcflStorageBuilder verifyInventoryDigest​(boolean verifyInventoryDigest)
        Configures whether inventory digests should be verified on read. This means computing the digest of the inventory file and comparing it with the digest in the inventory's sidecar. Default: true.
        Parameters:
        verifyInventoryDigest - true if inventory digests should be verified on read
        Returns:
        builder
      • build

        public FileSystemOcflStorage build()
        Builds a new FileSystemOcflStorage object
        Returns:
        file system storage