edu.ucsb.nceas.metacat.oaipmh.provider.server.crosswalk

## Class Eml2oai_dc

- java.lang.Object
- - ORG.oclc.oai.server.crosswalk.Crosswalk
  - - edu.ucsb.nceas.metacat.oaipmh.provider.server.crosswalk.Eml2oai_dc

-     public class Eml2oai_dc
      extends ORG.oclc.oai.server.crosswalk.Crosswalk

  Convert native "item" to oai_dc. In this case, the native "item" is assumed to already be formatted as an OAI element, with the possible exception that multiple metadataFormats may be present in the element. The "crosswalk", merely involves pulling out the one that is requested.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Eml2oai_dc(java.util.Properties properties)` The constructor assigns the schemaLocation associated with this crosswalk.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `createMetadata(java.lang.Object nativeItem)` Perform the actual crosswalk.
    `boolean` | `isAvailableFor(java.lang.Object nativeItem)` Can this nativeItem be represented in DC format?
    `static void` | `setDirPath(java.lang.String configDir)`

    - ### Methods inherited from class ORG.oclc.oai.server.crosswalk.Crosswalk

      `getContentType, getDocType, getEncoding, getNamespaceURL, getSchemaLocation, getSchemaURL, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Eml2oai_dc

          public Eml2oai_dc(java.util.Properties properties)
                     throws ORG.oclc.oai.server.verb.OAIInternalServerError

      The constructor assigns the schemaLocation associated with this crosswalk. Since the crosswalk is trivial in this case, no properties are utilized.
      Parameters:
        `properties` - properties that are needed to configure the crosswalk.
      Throws:
        `ORG.oclc.oai.server.verb.OAIInternalServerError`

  - ### Method Detail

    - #### setDirPath

          public static void setDirPath(java.lang.String configDir)

    - #### createMetadata

          public java.lang.String createMetadata(java.lang.Object nativeItem)
                                          throws ORG.oclc.oai.server.verb.CannotDisseminateFormatException

      Perform the actual crosswalk.
      Specified by:
        `createMetadata` in class `ORG.oclc.oai.server.crosswalk.Crosswalk`
      Parameters:
        `nativeItem` - the native "item". In this case, it is already formatted as an OAI element, with the possible exception that multiple metadataFormats are present in the element.
      Returns:
        a String containing the FileMap to be stored within the element.
      Throws:
        `ORG.oclc.oai.server.verb.CannotDisseminateFormatException` - nativeItem doesn't support this format.

    - #### isAvailableFor

          public boolean isAvailableFor(java.lang.Object nativeItem)

      Can this nativeItem be represented in DC format?
      Specified by:
        `isAvailableFor` in class `ORG.oclc.oai.server.crosswalk.Crosswalk`
      Parameters:
        `nativeItem` - a record in native format
      Returns:
        true if DC format is possible, false otherwise.

Copyright © 2023 Regents of the University of California. All Rights Reserved.