Interface Packer

    • Method Detail

      • pack

        File pack​(File packDir)
           throws org.dspace.authorize.AuthorizeException,
                  IOException,
                  SQLException
        Packs (maps) the contents of this object into an archive file.
        Parameters:
        packDir - the locus of the packing
        Returns:
        the packed archive file
        Throws:
        org.dspace.authorize.AuthorizeException - if authorize error
        IOException - if I/O error
        SQLException - if database error
      • unpack

        void unpack​(File archFile)
             throws org.dspace.authorize.AuthorizeException,
                    IOException,
                    SQLException
        Unpacks (maps) the contents of the passed archive file into this object.
        Parameters:
        archFile - the archive file to unpack
        Throws:
        org.dspace.authorize.AuthorizeException - if authorize error
        IOException - if I/O error
        SQLException - if database error
      • size

        long size​(String method)
           throws SQLException
        Estimate the size of the object as packed into a bag. This estimate uses any defined content filters.
        Parameters:
        method - how to estimate - not currently implemented
        Returns:
        the bagged object size in bytes
        Throws:
        SQLException - if database error
      • setContentFilter

        void setContentFilter​(String filter)
        Sets a filter on this packer. A filter will ignore (skip) object content when packing to a bag. Filter syntax: ["+"]{BundleName,}+ That is, a list of Item bundle names taken to be exclusions, unless preceeded by a '+", where the list is taken to be inclusive.
        Parameters:
        filter - filter
      • setReferenceFilter

        void setReferenceFilter​(String filter)