Class MCRPackerManager

java.lang.Object
org.mycore.services.packaging.MCRPackerManager

public class MCRPackerManager extends Object

Used to pack packages in a specific format, using MCRJobQueue.

You have to define a packer id and assign a packer class which extends MCRPacker.

MCR.Packaging.Packer.MyPackerID.Class = org.mycore.packaging.MyPackerClass

You now have to pass properties required by the packer:

MCR.Packaging.Packer.MyPackerID.somePropertyForPacker = value

Author:
Sebastian Hofmann (mcrshofm)
  • Constructor Details

    • MCRPackerManager

      public MCRPackerManager()
  • Method Details

    • startPacking

      public static MCRJob startPacking(Map<String,String> jobParameters) throws MCRUsageException, MCRAccessException
      Creates and starts a new PackagingJob.

      The rights you need to start a Packer depends on the implementation!

      Parameters:
      jobParameters - the parameters which will be passed to the job. (Should include a packer)
      Returns:
      the created MCRJob
      Throws:
      MCRUsageException - if invalid parameters are passed to the packer
      MCRAccessException - if the current user doesn't have the rights to use the packer(on a specific object).