<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xd="http://www.oxygenxml.com/ns/doc/xsl"
    xmlns:gfc="http://www.isotc211.org/2005/gfc" xmlns:gco="http://www.isotc211.org/2005/gco"
    xmlns:gmd="http://www.isotc211.org/2005/gmd" xmlns:xlink="http://www.w3.org/1999/xlink"
    exclude-result-prefixes="xs xd" version="2.0">
    
    <xd:doc scope="stylesheet">
        <xd:desc>
            <xd:p><xd:b>Created on:</xd:b> May 20, 2014</xd:p>
            <xd:p><xd:b>Author:</xd:b> matt</xd:p>
            <xd:p></xd:p>
        </xd:desc>
    </xd:doc>
    
    
    <xsl:template name="Census">
        <xsl:element name="gfc:definitionReference">
            <xsl:attribute name="xlink:title">U.S. Census Bureau</xsl:attribute>
            <xsl:attribute name="xlink:href">http://www.ngdc.noaa.gov/docucomp/eb139e38-ee29-4d59-b157-5e874d4420c4</xsl:attribute>
        </xsl:element>
    </xsl:template>
    
    <xsl:template name="USPS">
        <xsl:element name="gfc:definitionReference">
            <xsl:attribute name="xlink:title">U.S. Postal Service</xsl:attribute>
            <xsl:attribute name="xlink:href">https://www.ngdc.noaa.gov/docucomp/2de06071-f4d0-49b7-bd93-ba7a38e5d911</xsl:attribute>
        </xsl:element>
    </xsl:template>
    
    <xsl:template name="gmdTitle">
        <xsl:element name="gmd:title">
            <xsl:attribute name="gco:nilReason">inapplicable</xsl:attribute>
        </xsl:element>
    </xsl:template>
    
    <xsl:template name="gmdDate">
        <xsl:element name="gmd:date">
            <xsl:attribute name="gco:nilReason">unknown</xsl:attribute>
        </xsl:element>
    </xsl:template>
    
    <xsl:template name="cardinality">
        <xsl:element name="gfc:cardinality">
            <xsl:attribute name="gco:nilReason">unknown</xsl:attribute>
        </xsl:element>
    </xsl:template>
    
    <xsl:template name="gmdRole">
        <xsl:element name="gmd:role">
            <xsl:element name="gmd:CI_RoleCode">
                <xsl:attribute name="codeList">http://www.isotc211.org/2005/resources/Codelist/gmxCodelists.xml#CI_RoleCode</xsl:attribute>
                <xsl:attribute name="codeListValue">resourceProvider</xsl:attribute>
                resourceProvider
            </xsl:element>
        </xsl:element>
    </xsl:template>
    
</xsl:stylesheet>