Class MCROAIAdapter

java.lang.Object
org.mycore.oai.MCROAIAdapter
All Implemented Interfaces:
org.mycore.oai.pmh.dataprovider.OAIAdapter

public class MCROAIAdapter extends Object implements org.mycore.oai.pmh.dataprovider.OAIAdapter
Default MyCoRe OAIAdapter implementation.
Author:
Matthias Eichner
  • Field Details

  • Constructor Details

    • MCROAIAdapter

      public MCROAIAdapter()
  • Method Details

    • init

      public void init(String baseURL, String oaiConfiguration)
      Initialize the adapter.
      Parameters:
      baseURL - baseURL of the adapter e.g. http://localhost:8291/oai2
      oaiConfiguration - specifies the OAI-PMH configuration
    • getSetManager

      public MCROAISetManager getSetManager()
    • moveNamespaceDeclarationsToRoot

      public boolean moveNamespaceDeclarationsToRoot()
    • getObjectManager

      public MCROAIObjectManager getObjectManager()
    • getSearchManager

      public MCROAISearchManager getSearchManager()
    • getConfigPrefix

      public String getConfigPrefix()
    • getIdentify

      public MCROAIIdentify getIdentify()
      Specified by:
      getIdentify in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
    • getSets

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Set> getSets() throws org.mycore.oai.pmh.NoSetHierarchyException
      Specified by:
      getSets in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.NoSetHierarchyException
    • getSets

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Set> getSets(String resumptionToken) throws org.mycore.oai.pmh.NoSetHierarchyException, org.mycore.oai.pmh.BadResumptionTokenException
      Specified by:
      getSets in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.NoSetHierarchyException
      org.mycore.oai.pmh.BadResumptionTokenException
    • getSet

      public MCRSet getSet(String setSpec) throws org.mycore.oai.pmh.NoSetHierarchyException, org.mycore.oai.pmh.NoRecordsMatchException
      Specified by:
      getSet in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.NoSetHierarchyException
      org.mycore.oai.pmh.NoRecordsMatchException
    • getMetadataFormats

      public List<org.mycore.oai.pmh.MetadataFormat> getMetadataFormats()
      Specified by:
      getMetadataFormats in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
    • getMetadataFormat

      public org.mycore.oai.pmh.MetadataFormat getMetadataFormat(String prefix) throws org.mycore.oai.pmh.CannotDisseminateFormatException
      Specified by:
      getMetadataFormat in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.CannotDisseminateFormatException
    • getMetadataFormatMap

      protected Map<String,org.mycore.oai.pmh.MetadataFormat> getMetadataFormatMap()
    • getMetadataFormats

      public List<org.mycore.oai.pmh.MetadataFormat> getMetadataFormats(String identifier) throws org.mycore.oai.pmh.IdDoesNotExistException, org.mycore.oai.pmh.NoMetadataFormatsException
      Specified by:
      getMetadataFormats in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.IdDoesNotExistException
      org.mycore.oai.pmh.NoMetadataFormatsException
    • getRecord

      public org.mycore.oai.pmh.Record getRecord(String identifier, org.mycore.oai.pmh.MetadataFormat format) throws org.mycore.oai.pmh.CannotDisseminateFormatException, org.mycore.oai.pmh.IdDoesNotExistException
      Specified by:
      getRecord in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.CannotDisseminateFormatException
      org.mycore.oai.pmh.IdDoesNotExistException
    • getRecords

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Record> getRecords(String resumptionToken) throws org.mycore.oai.pmh.BadResumptionTokenException
      Specified by:
      getRecords in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.BadResumptionTokenException
    • getRecords

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Record> getRecords(org.mycore.oai.pmh.MetadataFormat format, org.mycore.oai.pmh.Set set, Instant from, Instant until) throws org.mycore.oai.pmh.CannotDisseminateFormatException, org.mycore.oai.pmh.NoSetHierarchyException, org.mycore.oai.pmh.NoRecordsMatchException
      Specified by:
      getRecords in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.CannotDisseminateFormatException
      org.mycore.oai.pmh.NoSetHierarchyException
      org.mycore.oai.pmh.NoRecordsMatchException
    • getHeaders

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Header> getHeaders(String resumptionToken) throws org.mycore.oai.pmh.BadResumptionTokenException
      Specified by:
      getHeaders in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.BadResumptionTokenException
    • getHeaders

      public org.mycore.oai.pmh.OAIDataList<org.mycore.oai.pmh.Header> getHeaders(org.mycore.oai.pmh.MetadataFormat format, org.mycore.oai.pmh.Set set, Instant from, Instant until) throws org.mycore.oai.pmh.CannotDisseminateFormatException, org.mycore.oai.pmh.NoSetHierarchyException, org.mycore.oai.pmh.NoRecordsMatchException
      Specified by:
      getHeaders in interface org.mycore.oai.pmh.dataprovider.OAIAdapter
      Throws:
      org.mycore.oai.pmh.CannotDisseminateFormatException
      org.mycore.oai.pmh.NoSetHierarchyException
      org.mycore.oai.pmh.NoRecordsMatchException