Class FilteredIdentifierProvider

java.lang.Object
org.dspace.identifier.IdentifierProvider
org.dspace.identifier.FilteredIdentifierProvider
Direct Known Subclasses:
DOIIdentifierProvider

public abstract class FilteredIdentifierProvider extends IdentifierProvider
This abstract class adds extra method signatures so that implementing IdentifierProviders can handle "skip filter" booleans, so that any configured filters can be skipped and DOI registration forced.
Version:
$Revision$
Author:
Kim Shepherd
  • Field Details

    • filter

      protected Filter filter
  • Constructor Details

    • FilteredIdentifierProvider

      public FilteredIdentifierProvider()
  • Method Details

    • setFilter

      public void setFilter(Filter filter)
      Setter for spring to set the default filter from the property in configuration XML
      Parameters:
      filter - - an object implementing the org.dspace.content.logic.Filter interface
    • register

      public abstract String register(Context context, DSpaceObject dso, Filter filter) throws IdentifierException
      Register a new identifier for a given DSpaceObject
      Parameters:
      context - - DSpace context
      dso - - DSpaceObject to use for identifier registration
      filter - - Logical item filter to determine whether this identifier should be registered
      Returns:
      identifier
      Throws:
      IdentifierException
    • register

      public abstract void register(Context context, DSpaceObject dso, String identifier, Filter filter) throws IdentifierException
      Register a specified identifier for a given DSpaceObject
      Parameters:
      context - - DSpace context
      dso - - DSpaceObject identified by the new identifier
      identifier - - String containing the identifier to register
      filter - - Logical item filter to determine whether this identifier should be registered
      Throws:
      IdentifierException
    • reserve

      public abstract void reserve(Context context, DSpaceObject dso, String identifier, Filter filter) throws IdentifierException, IllegalArgumentException, SQLException
      Reserve a specified identifier for a given DSpaceObject (eg. reserving a DOI online with a registration agency)
      Parameters:
      context - - DSpace context
      dso - - DSpaceObject identified by this identifier
      identifier - - String containing the identifier to reserve
      filter - - Logical item filter to determine whether this identifier should be reserved
      Throws:
      IdentifierException
      IllegalArgumentException
      SQLException
    • mint

      public abstract String mint(Context context, DSpaceObject dso, Filter filter) throws IdentifierException
      Mint a new identifier in DSpace - this is usually the first step of registration
      Parameters:
      context - - DSpace context
      dso - - DSpaceObject identified by the new identifier
      filter - - Logical item filter to determine whether this identifier should be registered
      Returns:
      a String containing the new identifier
      Throws:
      IdentifierException
    • checkMintable

      public abstract void checkMintable(Context context, DSpaceObject dso) throws IdentifierException
      Check configured item filters to see if this identifier is allowed to be minted
      Parameters:
      context - - DSpace context
      dso - - DSpaceObject to be inspected
      Throws:
      IdentifierException
    • checkMintable

      public abstract void checkMintable(Context context, Filter filter, DSpaceObject dso) throws IdentifierException
      Check configured item filters to see if this identifier is allowed to be minted
      Parameters:
      context - - DSpace context
      filter - - Logical item filter
      dso - - DSpaceObject to be inspected
      Throws:
      IdentifierException