LISTSERV mailing list manager LISTSERV 16.0

Help for MODS Archives


MODS Archives

MODS Archives


MODS@LISTSERV.LOC.GOV


View:

Message:

[

First

|

Previous

|

Next

|

Last

]

By Topic:

[

First

|

Previous

|

Next

|

Last

]

By Author:

[

First

|

Previous

|

Next

|

Last

]

Font:

Monospaced Font

LISTSERV Archives

LISTSERV Archives

MODS Home

MODS Home

MODS  December 2003

MODS December 2003

Subject:

MODS to Dublin Core mapping stylesheet and documentation

From:

Paul Fogel <[log in to unmask]>

Reply-To:

Metadata Object Description Schema List <[log in to unmask]>

Date:

Tue, 16 Dec 2003 11:14:57 -0800

Content-Type:

multipart/mixed

Parts/Attachments:

Parts/Attachments

text/plain (630 lines) , OAC-LSTA-MODS2DC.qdc2.xslt (394 lines) , mods2dcDocumentation.txt (178 lines)

Bruce had requested that I post these documents to the list. I hope that
someone may find them useful and I encourage all feedback and criticism.

These were developed to transform MODS (encoded in METS) into Dublin Core
for internal indexing purposes. While this is not a final version, it is
in production and seems to be doing what it is supposed to. A slightly
modified production version can be viewed at
http://ark.cdlib.org/xslt/extract-dc/OAC-LSTA-MODS2DC.qdc21.xsl.

I took the DC to MODS mapping stylesheet as a starting point, but as we all
know round-tripping is never the same both ways and I had to make a lot of
logical modification. Also, we are still working with MODS 2.0 so this
will need work when we make the transition.

I have attached the documents (an .xslt and a .txt) and have also pasted
them below. Again, please let me hear any opinions you may have.

Paul Fogel
California Digital Library
[log in to unmask]
510.987.0680


<xsl:stylesheet version="1.0"
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
   xmlns:xlink="http://www.w3.org/TR/xlink"
   xmlns:xsd="http://www.w3.org/2001/XMLSchema"
   xmlns:mets="http://www.loc.gov/METS/"
   xmlns:cdl="http://ark.cdlib.org/schemas/appqualifieddc/"
   xmlns:dcterms="http://purl.org/dc/terms/"
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:mods="http://www.loc.gov/mods/"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

   <xsl:strip-space elements="*"/>

   <xsl:output method="xml" indent="no"/>

   <xsl:template match="/">
     <xsl:apply-templates select="mets:mets"/>
   </xsl:template>

   <xsl:template match="mets:mets">
     <qdc2>
       <xsl:call-template name="title"/>
       <xsl:call-template name="creator"/>
       <xsl:call-template name="subject"/>
       <xsl:call-template name="description"/>
       <xsl:call-template name="publisher"/>
       <xsl:call-template name="contributor"/>
       <xsl:call-template name="date"/>
       <xsl:call-template name="type"/>
       <xsl:call-template name="format"/>
       <xsl:call-template name="identifier"/>
       <xsl:call-template name="source"/>
       <xsl:call-template name="language"/>
       <xsl:call-template name="relation"/>
       <xsl:call-template name="coverage"/>
       <xsl:call-template name="rights"/>
       <xsl:call-template name="dcterms"/>
     </qdc2>
   </xsl:template>

   <xsl:template name="title">
     <dc:title>
       <xsl:value-of select="//mods:mods/mods:titleInfo/mods:title"/>
       <xsl:if test="//mods:mods/mods:titleInfo/mods:subTitle">
         <xsl:text>: </xsl:text>
         <xsl:value-of select="//mods:mods/mods:titleInfo/mods:subTitle"/>
       </xsl:if>
     </dc:title>
   </xsl:template>

   <xsl:template name="creator">
     <!-- This may be used in the future for alternate encoding practices -->
     <!-- xsl:if test="contains(//mods:mods/mods:name/mods:role/mods:text,
'creator')" -->
       <!-- dc:creator-->
         <!-- xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/-->
       <!--/dc:creator-->
     <!--/xsl:if-->
     <xsl:if test="contains(//mods:mods/mods:name/mods:role, 'creator')">
       <dc:creator>
         <xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/>
       </dc:creator>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:recordInfo/mods:recordContentSource">
       <dc:creator>
         <xsl:value-of
select="//mods:mods/mods:recordInfo/mods:recordContentSource"/>
       </dc:creator>
     </xsl:if>
   </xsl:template>

   <xsl:template name="subject">
     <xsl:for-each select="//mods:mods/mods:subject/mods:topic">
       <dc:subject>
         <xsl:value-of select="."/>
       </dc:subject>
     </xsl:for-each>
     <xsl:for-each select="//mods:mods/mods:subject/mods:name">
       <dc:subject>
         <xsl:value-of select="."/>
       </dc:subject>
     </xsl:for-each>
     <xsl:if test="//mods:mods/mods:subject/mods:titleInfo/mods:title">
       <dc:subject>
         <xsl:value-of
select="//mods:mods/mods:subject/mods:titleInfo/mods:title"/>
       </dc:subject>
     </xsl:if>
   </xsl:template>

   <xsl:template name="description">
     <xsl:if test="//mods:mods/mods:abstract">
       <description>
         <xsl:value-of select="//mods:mods/mods:abstract"/>
       </description>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:tableOfContents">
       <dc:description>
         <xsl:value-of select="//mods:mods/mods:tableOfContents"/>
       </dc:description>
     </xsl:if>
     <xsl:for-each select="//mods:mods/mods:note">
       <dc:description>
         <xsl:value-of select="."/>
       </dc:description>
     </xsl:for-each>
     <xsl:if test="//mods:mods/mods:subject/mods:name/mods:description">
       <dc:description>
         <xsl:value-of
select="//mods:mods/mods:subject/mods:name/mods:description"/>
       </dc:description>
     </xsl:if>
   </xsl:template>

   <xsl:template name="publisher">
     <xsl:if test="//mods:mods/mods:originInfo/mods:publisher">
       <dc:publisher>
         <xsl:value-of select="//mods:mods/mods:originInfo/mods:publisher"/>
       </dc:publisher>
     </xsl:if>
     <!-- may be used in the future, if deemed appropriate -->
     <!--xsl:if test="//mods:mods/mods:recordInfo/mods:recordContentSource"-->
       <!--dc:publisher-->
         <!--xsl:value-of
select="//mods:mods/mods:recordInfo/mods:recordContentSource"/-->
       <!--/dc:publisher-->
     <!--/xsl:if-->
     <xsl:if test="//mods:mods/mods:publicationInfo/mods:publisher">
       <dc:publisher>
         <xsl:value-of
select="//mods:mods/mods:publicationInfo/mods:publisher"/>
       </dc:publisher>
     </xsl:if>
   </xsl:template>

   <xsl:template name="contributor">
     <xsl:if test="contains(//mods:mods/mods:name/mods:role/mods:text,
'contributor')">
       <dc:contributor>
         <xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/>
       </dc:contributor>
     </xsl:if>
   </xsl:template>

   <xsl:template name="date">
     <xsl:if test="//mods:mods/mods:originInfo/mods:dateIssued">
       <dc:date>
         <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateIssued"/>
       </dc:date>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:publicationInfo/mods:dateIssued">
       <dc:date>
         <xsl:value-of
select="//mods:mods/mods:publicationInfo/mods:dateIssued"/>
       </dc:date>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:originInfo/mods:dateCreated">
       <dc:date>
         <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCreated"/>
       </dc:date>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:originInfo/mods:dateCaptured">
       <dc:date>
         <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCaptured"/>
       </dc:date>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:originInfo/mods:dateOther">
       <dc:date>
         <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateOther"/>
       </dc:date>
     </xsl:if>
   </xsl:template>

   <xsl:template name="type">
     <xsl:if test="//mods:mods/mods:typeOfResource">
     <dc:type>
         <xsl:value-of select="//mods:mods/mods:typeOfResource"/>
     </dc:type>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:genre">
     <dc:type>
         <xsl:value-of select="//mods:mods/mods:genre"/>
     </dc:type>
     </xsl:if>
   </xsl:template>

   <xsl:template name="format">
     <xsl:if test="//mods:mods/mods:physicalDescription/mods:extent">
       <dc:format>
         <xsl:value-of
select="//mods:mods/mods:physicalDescription/mods:extent"/>
       </dc:format>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:physicalDescription/mods:form">
       <dc:format>
         <xsl:value-of
select="//mods:mods/mods:physicalDescription/mods:form"/>
       </dc:format>
     </xsl:if>
     <xsl:if
test="//mods:mods/mods:physicalDescription/mods:internetMediaType">
       <dc:format>
         <xsl:value-of
select="//mods:mods/mods:physicalDescription/mods:internetMediaType"/>
       </dc:format>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:physicalDescription/mods:digitalOrigin">
       <dc:format>
         <xsl:value-of
select="//mods:mods/mods:physicalDescription/mods:digitalOrigin"/>
       </dc:format>
     </xsl:if>
     <xsl:if test="//mods:mods/mods:physicalDescription/mods:note">
       <dc:format>
         <xsl:value-of
select="//mods:mods/mods:physicalDescription/mods:note"/>
       </dc:format>
     </xsl:if>
   </xsl:template>

   <xsl:template name="identifier">
     <xsl:for-each select="//mods:mods/mods:identifier">
       <xsl:choose>
         <xsl:when test="@type='isbn'">
           <dc:identifier>
             <xsl:text>isbn: </xsl:text>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:when>
         <xsl:when test="@type='issn'">
           <dc:identifier>
             <xsl:text>issn: </xsl:text>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:when>
         <xsl:when test="@type='doi'">
           <dc:identifier>
             <xsl:text>doi: </xsl:text>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:when>
         <xsl:when test="@type='lccn'">
           <dc:identifier>
             <xsl:text>lccn: </xsl:text>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:when>
         <xsl:when test="@type='uri'">
           <dc:identifier>
             <xsl:text>uri: </xsl:text>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:when>
         <xsl:otherwise>
           <dc:identifier>
             <xsl:value-of select="."/>
           </dc:identifier>
         </xsl:otherwise>
       </xsl:choose>
     </xsl:for-each>
   </xsl:template>

   <xsl:template name="source">
     <xsl:if test="//mods:mods/mods:relatedItem[@type='original']">
       <xsl:for-each select="//mods:mods/mods:relatedItem[@type='original']/*">
         <dc:source>
           <xsl:value-of select="."/>
         </dc:source>
       </xsl:for-each>
     </xsl:if>
   </xsl:template>

   <xsl:template name="language">
     <dc:language>
       <xsl:value-of select="//mods:mods/mods:language"/>
     </dc:language>
   </xsl:template>

   <xsl:template name="relation">
     <xsl:for-each select="//mods:mods/mods:relatedItem">
       <xsl:choose>
         <xsl:when test="@type='original'"/>
         <xsl:when test="@type='series'"/>
         <xsl:otherwise>
           <xsl:apply-templates mode="makeRelations"/>
         </xsl:otherwise>
       </xsl:choose>
     </xsl:for-each>
     <xsl:if test="//*[local-name()='relation']">
       <dc:relation>
         <xsl:value-of select="//*[local-name()='relation']"/>
       </dc:relation>
     </xsl:if>
   </xsl:template>

<xsl:template match="*" mode="makeRelations">
   <xsl:apply-templates mode="makeRelations"/>
</xsl:template>

<xsl:template match="text()" mode="makeRelations">
   <xsl:if test="normalize-space(.) != ''">
     <dc:relation>
       <xsl:value-of select="normalize-space(.)"/>
     </dc:relation>
   </xsl:if>
</xsl:template>

<xsl:template name="coverage">
   <xsl:if test="//mods:mods/mods:subject/mods:geographic">
     <dc:coverage>
       <xsl:value-of select="//mods:mods/mods:subject/mods:geographic"/>
     </dc:coverage>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:subject/mods:temporal">
     <dc:coverage>
       <xsl:value-of select="//mods:mods/mods:subject/mods:temporal"/>
     </dc:coverage>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:subject/mods:hierarchicalGeographic">
     <xsl:apply-templates mode="coverage1"
select="//mods:mods/mods:subject/mods:hierarchicalGeographic"/>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:subject/mods:cartographic">
     <xsl:apply-templates mode="coverage2"
select="//mods:mods/mods:subject/mods:cartographic"/>
   </xsl:if>
   <xsl:for-each select="//mods:mods/mods:classification">
     <dc:coverage>
       <xsl:value-of select="."/>
     </dc:coverage>
   </xsl:for-each>
</xsl:template>

<xsl:template match="*" mode="coverage1">
   <xsl:apply-templates mode="coverage1"/>
</xsl:template>

<xsl:template match="text()" mode="coverage1">
   <xsl:if test="normalize-space(.) != ''">
     <dc:coverage>
       <xsl:value-of select="normalize-space(.)"/>
     </dc:coverage>
   </xsl:if>
</xsl:template>

<xsl:template match="*" mode="coverage2">
   <xsl:apply-templates mode="coverage2"/>
</xsl:template>

<xsl:template match="text()" mode="coverage2">
   <xsl:if test="normalize-space(.) != ''">
     <dc:coverage>
       <xsl:value-of select="normalize-space(.)"/>
     </dc:coverage>
   </xsl:if>
</xsl:template>

<xsl:template name="rights">
   <xsl:if test="//mods:mods/mods:accessCondition">
     <dc:rights>
       <xsl:value-of select="//mods:mods/mods:accessCondition"/>
     </dc:rights>
   </xsl:if>
</xsl:template>

<xsl:template name="dcterms">
   <xsl:if test="//mods:mods/mods:abstract">
     <dcterms:abstract>
       <xsl:value-of select="//mods:mods/mods:abstract"/>
     </dcterms:abstract>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:recordInfo/mods:recordCreationDate">
     <dcterms:created>
       <xsl:value-of
select="//mods:mods/mods:recordInfo/mods:recordCreationDate"/>
     </dcterms:created>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:originInfo/mods:dateCreated">
     <dcterms:created>
       <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCreated"/>
     </dcterms:created>
   </xsl:if>
   <xsl:if test="//mods:mods/mods:recordInfo/mods:recordChangeDate">
     <dcterms:modified>
       <xsl:value-of
select="//mods:mods/mods:recordInfo/mods:recordChangeDate"/>
     </dcterms:modified>
   </xsl:if>
   <xsl:for-each select="//mods:mods/mods:relatedItem">
     <xsl:choose>
       <xsl:when test="@type='series'">
         <xsl:apply-templates mode="makeIsPartOf"/>
       </xsl:when>
     </xsl:choose>
   </xsl:for-each>
</xsl:template>

<xsl:template match="*" mode="makeIsPartOf">
   <xsl:apply-templates mode="makeIsPartOf"/>
</xsl:template>

<xsl:template match="text()" mode="makeIsPartOf">
   <xsl:if test="normalize-space(.) != ''">
     <dcterms:isPartOf>
       <xsl:value-of select="normalize-space(.)"/>
     </dcterms:isPartOf>
   </xsl:if>
</xsl:template>

</xsl:stylesheet>


MODS to Dublin Core Mapping



By Dublin Core Element, from MODS Element

Title:
//mods/titleInfo/title - A conditional IF statement is included to catch
<titleInfo><subTitle> and append it to the title, separated by colon space
(: ).

Creator:
//mods/name/namePart - when //mods/name/role[. = 'creator']
//mods/recordInfo/recordContentSource

Subject:
//mods/subject/topic
//mods/subject/name
//mods/subject/titleInfo/title

Description:
//mods/abstract
//mods/tableOfContents
//mods/note
//mods/subject/name<description>

Publisher:
//mods/originInfo/publisher
//mods/publicationInfo/publisher - to accommodate earlier encoding
practices; this usage is outdated

Contributor:
//mods/name/namePart - when //mods/name/role/text[. = 'contributor']

Date:
Mapped from:
//mods/originInfo/dateIssued
//mods/originInfo/dateCreated
//mods/originInfo/dateCaptured
//mods/originInfo/dateOther
//mods/publicationInfo/dateIssued - to accommodate earlier encoding
practices; this usage is outdated

Type:
//mods/typeOfResource
//mods/genre

Format:
//mods/physicalDescription/extent
//mods/physicalDescription/form
//mods/physicalDescription/internetMediaType
//mods/physicalDescription/digitalOrigin
//mods/physicalDescription/note

Identifier:
//mods/identifier - If @TYPE= 'isbn', 'issn', 'lccn', 'doi' or 'uri', then
this value precedes the data, separated by colon space.
         Example: <identifier>uri:
http://www.ucpress.edu/books/pages/6178.html&amp;isbn=0520081994</identifier>
         If there is no TYPE attribute, or if it is not set to one of these
values, the data is mapped without qualification.

Source:
//mods/relatedItem[@TYPE='original']

Language:
//mods/language

Relation:
//mods/relatedItem - except when relatedItem[(@TYPE='original') or
(@TYPE='series')]

Coverage:
Mapped from:
//mods/subject/geographic
//mods/subject/temporal
//mods/subject/hierarchicalGeographic
//mods/subject/cartographic
//mods/classification
         The hierarchicalGeographic and cartographic nodes are flattened so
that repeating values as well as sub-elements (and their children) are
strung into one element.

Rights:
//mods/accessCondition

DCTerms:Abstract:
//mods/abstract - this data is also mapped (see above) into Description, so
that data is not lost in Unqualified Dublin Core.

DCTerms:Created
//mods/recordInfo/recordCreationDate. This is also mapped to Date, so that
data is not lost in Unqualified Dublin Core.

DCTerms:Modified
//mods/recordInfo/recordChangeDate. This is also mapped to Date, so that
data is not lost in Unqualified Dublin Core.

DCTerms:isPartOf
//mods/relatedItem - when //mods/relatedItem[@TYPE='series']. This is also
mapped to Relation, so that data is not lost in Unqualified Dublin Core.







By MODS Element, to Dublin Core Element

ELEMENT MAPPED TO
//mods/titleInfo/title title
//mods/titleInfo/subTitle title
//mods/titleInfo/partNumber ignored
//mods/titleInfo/partName ignored
//mods/titleInfo/nonSort ignored

//mods/name/namePart creator, contributor (see
above)
//mods/name/displayForm ignored
//mods/name/affiliation ignored
//mods/name/role Used to assign creator and
contributor, otherwise ignored.
//mods/name/description description

//mods/typeOfResource type

//mods/genre type

//mods/originInfo/place ignored
//mods/originInfo/publisher publisher
//mods/originInfo/dateIssued date
//mods/originInfo/dateCreated date, dcterms:created
//mods/originInfo/dateCaptured date
//mods/originInfo/dateOther date
//mods/originInfo/edition ignored
//mods/originInfo/issuance ignored
//mods/originInfo/frequency ignored

//mods/language language

//mods/physicalDescription/form format
//mods/physicalDescription/reformattingQuality ignored
//mods/physicalDescription/internetMediaType format
//mods/physicalDescription/extent format
//mods/physicalDescription/digitalOrigin format
//mods/physicalDescription/note format

//mods/abstract description, dcterms:absctract

//mods/tableOfContents description

//mods/targetAudience ignored

//mods/note description

//mods/subject/topic subject
//mods/subject/geographical coverage
//mods/subject/temporal coverage
//mods/subject/titleInfo/title subject
         (other subelements for titleInfo ignored)
//mods/subject/name<description> subject
         (other subelements for name ignored)
//mods/subject/hierarchicalGeographic coverage
         (subelements flattened to appear in one string)
//mods/subject/cartographic coverage
         (subelements flattened to appear in one string)
//mods/classification coverage

//mods/relatedItem[@type='original'] source
//mods/relatedItem[@type='series'] dcterms:isPartOf
//mods/relatedItem[@type='*'] relation
         (subelements flattened to appear in one string)

//mods/identifier identifier
         (if type is issn, isbn, lccn, uri, or doi, it is applied at
beginning of data string; otherwise data is applied as is)
         Ex. <dc:identifier>isbn: 0123456789</dc:identifier>
             <dc:identifier>12-34567-8901234-5-67</dc:identifier>

//mods/location ignored

//mods/accessCondition rights

//mods/extension ignored

//mods/recordInfo/recordContentSource creator,
//mods/recordInfo/recordCreationDate dcterms:created
//mods/recordInfo/recordChangeDate dcterms:modified
//mods/recordInfo/recordIdentifier ignored
//mods/recordInfo/languageOfCataloging ignored




<xsl:stylesheet version="1.0"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:xlink="http://www.w3.org/TR/xlink"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:mets="http://www.loc.gov/METS/"
  xmlns:cdl="http://ark.cdlib.org/schemas/appqualifieddc/"
  xmlns:dcterms="http://purl.org/dc/terms/"
  xmlns:dc="http://purl.org/dc/elements/1.1/"
  xmlns:mods="http://www.loc.gov/mods/"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

  <xsl:strip-space elements="*"/>

  <xsl:output method="xml" indent="no"/>

  <xsl:template match="/">
    <xsl:apply-templates select="mets:mets"/>
  </xsl:template>

  <xsl:template match="mets:mets">
    <qdc2>
      <xsl:call-template name="title"/>
      <xsl:call-template name="creator"/>
      <xsl:call-template name="subject"/>
      <xsl:call-template name="description"/>
      <xsl:call-template name="publisher"/>
      <xsl:call-template name="contributor"/>
      <xsl:call-template name="date"/>
      <xsl:call-template name="type"/>
      <xsl:call-template name="format"/>
      <xsl:call-template name="identifier"/>
      <xsl:call-template name="source"/>
      <xsl:call-template name="language"/>
      <xsl:call-template name="relation"/>
      <xsl:call-template name="coverage"/>
      <xsl:call-template name="rights"/>
      <xsl:call-template name="dcterms"/>
    </qdc2>
  </xsl:template>

  <xsl:template name="title">
    <dc:title>
      <xsl:value-of select="//mods:mods/mods:titleInfo/mods:title"/>
      <xsl:if test="//mods:mods/mods:titleInfo/mods:subTitle">
        <xsl:text>: </xsl:text>
        <xsl:value-of select="//mods:mods/mods:titleInfo/mods:subTitle"/>
      </xsl:if>
    </dc:title>
  </xsl:template>

  <xsl:template name="creator">
    <!-- This may be used in the future for alternate encoding practices -->
    <!-- xsl:if test="contains(//mods:mods/mods:name/mods:role/mods:text, 'creator')" -->
      <!-- dc:creator-->
        <!-- xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/-->
      <!--/dc:creator-->
    <!--/xsl:if-->
    <xsl:if test="contains(//mods:mods/mods:name/mods:role, 'creator')">
      <dc:creator>
        <xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/>
      </dc:creator>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:recordInfo/mods:recordContentSource">
      <dc:creator>
        <xsl:value-of select="//mods:mods/mods:recordInfo/mods:recordContentSource"/>
      </dc:creator>
    </xsl:if>
  </xsl:template>

  <xsl:template name="subject">
    <xsl:for-each select="//mods:mods/mods:subject/mods:topic">
      <dc:subject>
        <xsl:value-of select="."/>
      </dc:subject>
    </xsl:for-each>
    <xsl:for-each select="//mods:mods/mods:subject/mods:name">
      <dc:subject>
        <xsl:value-of select="."/>
      </dc:subject>
    </xsl:for-each>
    <xsl:if test="//mods:mods/mods:subject/mods:titleInfo/mods:title">
      <dc:subject>
        <xsl:value-of select="//mods:mods/mods:subject/mods:titleInfo/mods:title"/>
      </dc:subject>
    </xsl:if>
  </xsl:template>

  <xsl:template name="description">
    <xsl:if test="//mods:mods/mods:abstract">
      <description>
        <xsl:value-of select="//mods:mods/mods:abstract"/>
      </description>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:tableOfContents">
      <dc:description>
        <xsl:value-of select="//mods:mods/mods:tableOfContents"/>
      </dc:description>
    </xsl:if>
    <xsl:for-each select="//mods:mods/mods:note">
      <dc:description>
        <xsl:value-of select="."/>
      </dc:description>
    </xsl:for-each>
    <xsl:if test="//mods:mods/mods:subject/mods:name/mods:description">
      <dc:description>
        <xsl:value-of select="//mods:mods/mods:subject/mods:name/mods:description"/>
      </dc:description>
    </xsl:if>
  </xsl:template>

  <xsl:template name="publisher">
    <xsl:if test="//mods:mods/mods:originInfo/mods:publisher">
      <dc:publisher>
        <xsl:value-of select="//mods:mods/mods:originInfo/mods:publisher"/>
      </dc:publisher>
    </xsl:if>
    <!-- may be used in the future, if deemed appropriate -->
    <!--xsl:if test="//mods:mods/mods:recordInfo/mods:recordContentSource"-->
      <!--dc:publisher-->
        <!--xsl:value-of select="//mods:mods/mods:recordInfo/mods:recordContentSource"/-->
      <!--/dc:publisher-->
    <!--/xsl:if-->
    <xsl:if test="//mods:mods/mods:publicationInfo/mods:publisher">
      <dc:publisher>
        <xsl:value-of select="//mods:mods/mods:publicationInfo/mods:publisher"/>
      </dc:publisher>
    </xsl:if>
  </xsl:template>

  <xsl:template name="contributor">
    <xsl:if test="contains(//mods:mods/mods:name/mods:role/mods:text, 'contributor')">
      <dc:contributor>
        <xsl:value-of select="//mods:mods/mods:name[1]/mods:namePart"/>
      </dc:contributor>
    </xsl:if>
  </xsl:template>

  <xsl:template name="date">
    <xsl:if test="//mods:mods/mods:originInfo/mods:dateIssued">
      <dc:date>
        <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateIssued"/>
      </dc:date>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:publicationInfo/mods:dateIssued">
      <dc:date>
        <xsl:value-of select="//mods:mods/mods:publicationInfo/mods:dateIssued"/>
      </dc:date>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:originInfo/mods:dateCreated">
      <dc:date>
        <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCreated"/>
      </dc:date>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:originInfo/mods:dateCaptured">
      <dc:date>
        <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCaptured"/>
      </dc:date>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:originInfo/mods:dateOther">
      <dc:date>
        <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateOther"/>
      </dc:date>
    </xsl:if>
  </xsl:template>

  <xsl:template name="type">
    <xsl:if test="//mods:mods/mods:typeOfResource">
    <dc:type>
        <xsl:value-of select="//mods:mods/mods:typeOfResource"/>
    </dc:type>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:genre">
    <dc:type>
        <xsl:value-of select="//mods:mods/mods:genre"/>
    </dc:type>
    </xsl:if>
  </xsl:template>

  <xsl:template name="format">
    <xsl:if test="//mods:mods/mods:physicalDescription/mods:extent">
      <dc:format>
        <xsl:value-of select="//mods:mods/mods:physicalDescription/mods:extent"/>
      </dc:format>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:physicalDescription/mods:form">
      <dc:format>
        <xsl:value-of select="//mods:mods/mods:physicalDescription/mods:form"/>
      </dc:format>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:physicalDescription/mods:internetMediaType">
      <dc:format>
        <xsl:value-of select="//mods:mods/mods:physicalDescription/mods:internetMediaType"/>
      </dc:format>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:physicalDescription/mods:digitalOrigin">
      <dc:format>
        <xsl:value-of select="//mods:mods/mods:physicalDescription/mods:digitalOrigin"/>
      </dc:format>
    </xsl:if>
    <xsl:if test="//mods:mods/mods:physicalDescription/mods:note">
      <dc:format>
        <xsl:value-of select="//mods:mods/mods:physicalDescription/mods:note"/>
      </dc:format>
    </xsl:if>
  </xsl:template>

  <xsl:template name="identifier">
    <xsl:for-each select="//mods:mods/mods:identifier">
      <xsl:choose>
        <xsl:when test="@type='isbn'">
          <dc:identifier>
            <xsl:text>isbn: </xsl:text>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:when>
        <xsl:when test="@type='issn'">
          <dc:identifier>
            <xsl:text>issn: </xsl:text>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:when>
        <xsl:when test="@type='doi'">
          <dc:identifier>
            <xsl:text>doi: </xsl:text>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:when>
        <xsl:when test="@type='lccn'">
          <dc:identifier>
            <xsl:text>lccn: </xsl:text>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:when>
        <xsl:when test="@type='uri'">
          <dc:identifier>
            <xsl:text>uri: </xsl:text>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:when>
        <xsl:otherwise>
          <dc:identifier>
            <xsl:value-of select="."/>
          </dc:identifier>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:for-each>
  </xsl:template>

  <xsl:template name="source">
    <xsl:if test="//mods:mods/mods:relatedItem[@type='original']">
      <xsl:for-each select="//mods:mods/mods:relatedItem[@type='original']/*">
        <dc:source>
          <xsl:value-of select="."/>
        </dc:source>
      </xsl:for-each>
    </xsl:if>
  </xsl:template>

  <xsl:template name="language">
    <dc:language>
      <xsl:value-of select="//mods:mods/mods:language"/>
    </dc:language>
  </xsl:template>

  <xsl:template name="relation">
    <xsl:for-each select="//mods:mods/mods:relatedItem">
      <xsl:choose>
        <xsl:when test="@type='original'"/>
        <xsl:when test="@type='series'"/>
        <xsl:otherwise>
          <xsl:apply-templates mode="makeRelations"/>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:for-each>
    <xsl:if test="//*[local-name()='relation']">
      <dc:relation>
        <xsl:value-of select="//*[local-name()='relation']"/>
      </dc:relation>
    </xsl:if>
  </xsl:template>

<xsl:template match="*" mode="makeRelations">
  <xsl:apply-templates mode="makeRelations"/>
</xsl:template>

<xsl:template match="text()" mode="makeRelations">
  <xsl:if test="normalize-space(.) != ''">
    <dc:relation>
      <xsl:value-of select="normalize-space(.)"/>
    </dc:relation>
  </xsl:if>
</xsl:template>

<xsl:template name="coverage">
  <xsl:if test="//mods:mods/mods:subject/mods:geographic">
    <dc:coverage>
      <xsl:value-of select="//mods:mods/mods:subject/mods:geographic"/>
    </dc:coverage>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:subject/mods:temporal">
    <dc:coverage>
      <xsl:value-of select="//mods:mods/mods:subject/mods:temporal"/>
    </dc:coverage>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:subject/mods:hierarchicalGeographic">
    <xsl:apply-templates mode="coverage1" select="//mods:mods/mods:subject/mods:hierarchicalGeographic"/>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:subject/mods:cartographic">
    <xsl:apply-templates mode="coverage2" select="//mods:mods/mods:subject/mods:cartographic"/>
  </xsl:if>
  <xsl:for-each select="//mods:mods/mods:classification">
    <dc:coverage>
      <xsl:value-of select="."/>
    </dc:coverage>
  </xsl:for-each>
</xsl:template>

<xsl:template match="*" mode="coverage1">
  <xsl:apply-templates mode="coverage1"/>
</xsl:template>

<xsl:template match="text()" mode="coverage1">
  <xsl:if test="normalize-space(.) != ''">
    <dc:coverage>
      <xsl:value-of select="normalize-space(.)"/>
    </dc:coverage>
  </xsl:if>
</xsl:template>

<xsl:template match="*" mode="coverage2">
  <xsl:apply-templates mode="coverage2"/>
</xsl:template>

<xsl:template match="text()" mode="coverage2">
  <xsl:if test="normalize-space(.) != ''">
    <dc:coverage>
      <xsl:value-of select="normalize-space(.)"/>
    </dc:coverage>
  </xsl:if>
</xsl:template>

<xsl:template name="rights">
  <xsl:if test="//mods:mods/mods:accessCondition">
    <dc:rights>
      <xsl:value-of select="//mods:mods/mods:accessCondition"/>
    </dc:rights>
  </xsl:if>
</xsl:template>

<xsl:template name="dcterms">
  <xsl:if test="//mods:mods/mods:abstract">
    <dcterms:abstract>
      <xsl:value-of select="//mods:mods/mods:abstract"/>
    </dcterms:abstract>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:recordInfo/mods:recordCreationDate">
    <dcterms:created>
      <xsl:value-of select="//mods:mods/mods:recordInfo/mods:recordCreationDate"/>
    </dcterms:created>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:originInfo/mods:dateCreated">
    <dcterms:created>
      <xsl:value-of select="//mods:mods/mods:originInfo/mods:dateCreated"/>
    </dcterms:created>
  </xsl:if>
  <xsl:if test="//mods:mods/mods:recordInfo/mods:recordChangeDate">
    <dcterms:modified>
      <xsl:value-of select="//mods:mods/mods:recordInfo/mods:recordChangeDate"/>
    </dcterms:modified>
  </xsl:if>
  <xsl:for-each select="//mods:mods/mods:relatedItem">
    <xsl:choose>
      <xsl:when test="@type='series'">
        <xsl:apply-templates mode="makeIsPartOf"/>
      </xsl:when>
    </xsl:choose>
  </xsl:for-each>
</xsl:template>

<xsl:template match="*" mode="makeIsPartOf">
  <xsl:apply-templates mode="makeIsPartOf"/>
</xsl:template>

<xsl:template match="text()" mode="makeIsPartOf">
  <xsl:if test="normalize-space(.) != ''">
    <dcterms:isPartOf>
      <xsl:value-of select="normalize-space(.)"/>
    </dcterms:isPartOf>
  </xsl:if>
</xsl:template>

</xsl:stylesheet>


MODS to Dublin Core Mapping



By Dublin Core Element, from MODS Element

Title:
//mods/titleInfo/title - A conditional IF statement is included to catch <titleInfo><subTitle> and append it to the title, separated by colon space (: ).

Creator:
//mods/name/namePart - when //mods/name/role[. = 'creator']
//mods/recordInfo/recordContentSource

Subject:
//mods/subject/topic
//mods/subject/name
//mods/subject/titleInfo/title

Description:
//mods/abstract
//mods/tableOfContents
//mods/note
//mods/subject/name<description>

Publisher:
//mods/originInfo/publisher
//mods/publicationInfo/publisher - to accommodate earlier encoding practices; this usage is outdated

Contributor:
//mods/name/namePart - when //mods/name/role/text[. = 'contributor']

Date:
Mapped from:
//mods/originInfo/dateIssued
//mods/originInfo/dateCreated
//mods/originInfo/dateCaptured
//mods/originInfo/dateOther
//mods/publicationInfo/dateIssued - to accommodate earlier encoding practices; this usage is outdated

Type:
//mods/typeOfResource
//mods/genre

Format:
//mods/physicalDescription/extent
//mods/physicalDescription/form
//mods/physicalDescription/internetMediaType
//mods/physicalDescription/digitalOrigin
//mods/physicalDescription/note

Identifier:
//mods/identifier - If @TYPE= 'isbn', 'issn', 'lccn', 'doi' or 'uri', then this value precedes the data, separated by colon space.
        Example: <identifier>uri: http://www.ucpress.edu/books/pages/6178.html&amp;isbn=0520081994</identifier>
        If there is no TYPE attribute, or if it is not set to one of these values, the data is mapped without qualification.

Source:
//mods/relatedItem[@TYPE='original']

Language:
//mods/language

Relation:
//mods/relatedItem - except when relatedItem[(@TYPE='original') or (@TYPE='series')]

Coverage:
Mapped from:
//mods/subject/geographic
//mods/subject/temporal
//mods/subject/hierarchicalGeographic
//mods/subject/cartographic
//mods/classification
        The hierarchicalGeographic and cartographic nodes are flattened so that repeating values as well as sub-elements (and their children) are strung into one element.

Rights:
//mods/accessCondition

DCTerms:Abstract:
//mods/abstract - this data is also mapped (see above) into Description, so that data is not lost in Unqualified Dublin Core.

DCTerms:Created
//mods/recordInfo/recordCreationDate. This is also mapped to Date, so that data is not lost in Unqualified Dublin Core.

DCTerms:Modified
//mods/recordInfo/recordChangeDate. This is also mapped to Date, so that data is not lost in Unqualified Dublin Core.

DCTerms:isPartOf
//mods/relatedItem - when //mods/relatedItem[@TYPE='series']. This is also mapped to Relation, so that data is not lost in Unqualified Dublin Core.







By MODS Element, to Dublin Core Element

ELEMENT MAPPED TO
//mods/titleInfo/title title
//mods/titleInfo/subTitle title
//mods/titleInfo/partNumber ignored
//mods/titleInfo/partName ignored
//mods/titleInfo/nonSort ignored

//mods/name/namePart creator, contributor (see above)
//mods/name/displayForm ignored
//mods/name/affiliation ignored
//mods/name/role Used to assign creator and contributor, otherwise ignored.
//mods/name/description description

//mods/typeOfResource type

//mods/genre type

//mods/originInfo/place ignored
//mods/originInfo/publisher publisher
//mods/originInfo/dateIssued date
//mods/originInfo/dateCreated date, dcterms:created
//mods/originInfo/dateCaptured date
//mods/originInfo/dateOther date
//mods/originInfo/edition ignored
//mods/originInfo/issuance ignored
//mods/originInfo/frequency ignored

//mods/language language

//mods/physicalDescription/form format
//mods/physicalDescription/reformattingQuality ignored
//mods/physicalDescription/internetMediaType format
//mods/physicalDescription/extent format
//mods/physicalDescription/digitalOrigin format
//mods/physicalDescription/note format

//mods/abstract description, dcterms:absctract

//mods/tableOfContents description

//mods/targetAudience ignored

//mods/note description

//mods/subject/topic subject
//mods/subject/geographical coverage
//mods/subject/temporal coverage
//mods/subject/titleInfo/title subject
        (other subelements for titleInfo ignored)
//mods/subject/name<description> subject
        (other subelements for name ignored)
//mods/subject/hierarchicalGeographic coverage
        (subelements flattened to appear in one string)
//mods/subject/cartographic coverage
        (subelements flattened to appear in one string)
//mods/classification coverage

//mods/relatedItem[@type='original'] source
//mods/relatedItem[@type='series'] dcterms:isPartOf
//mods/relatedItem[@type='*'] relation
        (subelements flattened to appear in one string)

//mods/identifier identifier
        (if type is issn, isbn, lccn, uri, or doi, it is applied at beginning of data string; otherwise data is applied as is)
        Ex. <dc:identifier>isbn: 0123456789</dc:identifier>
            <dc:identifier>12-34567-8901234-5-67</dc:identifier>

//mods/location ignored

//mods/accessCondition rights

//mods/extension ignored

//mods/recordInfo/recordContentSource creator,
//mods/recordInfo/recordCreationDate dcterms:created
//mods/recordInfo/recordChangeDate dcterms:modified
//mods/recordInfo/recordIdentifier ignored
//mods/recordInfo/languageOfCataloging ignored



Top of Message | Previous Page | Permalink

Advanced Options


Options

Log In

Log In

Get Password

Get Password


Search Archives

Search Archives


Subscribe or Unsubscribe

Subscribe or Unsubscribe


Archives

November 2022
October 2022
September 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
December 2021
November 2021
October 2021
September 2021
August 2021
May 2021
November 2020
September 2020
August 2020
July 2020
May 2020
April 2020
March 2020
February 2020
January 2020
December 2019
October 2019
September 2019
August 2019
June 2019
May 2019
March 2019
February 2019
January 2019
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
February 2018
January 2018
December 2017
November 2017
October 2017
September 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
December 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
February 2008
January 2008
December 2007
November 2007
October 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002

ATOM RSS1 RSS2



LISTSERV.LOC.GOV

CataList Email List Search Powered by the LISTSERV Email List Manager