Project

General

Profile

1
<RESOURCE_PROFILE>
2
    <HEADER>
3
        <RESOURCE_IDENTIFIER value="8ca058a9-2bcc-47a0-99eb-4df6b9cdf7a1_VHJhbnNmb3JtYXRpb25SdWxlRFNSZXNvdXJjZXMvVHJhbnNmb3JtYXRpb25SdWxlRFNSZXNvdXJjZVR5cGU="/>
4
        <RESOURCE_TYPE value="TransformationRuleDSResourceType"/>
5
        <RESOURCE_KIND value="TransformationRuleDSResources"/>
6
        <RESOURCE_URI value=""/>
7
        <DATE_OF_CREATION value="2019-09-13T14:57:57+02:00"/>
8
    </HEADER>
9
    <BODY>
10
        <CONFIGURATION>
11
            <SOURCE_METADATA_FORMAT interpretation="final" layout="oai" name="native"/>
12
            <SINK_METADATA_FORMAT name="datacite"/>
13
            <IMPORTED/>
14
            <SCRIPT>
15
                <TITLE>native to datacite</TITLE>
16
                <CODE>
17
                    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dnet="eu.dnetlib.data.utils.XsltFunctions" xmlns:oai="http://www.openarchives.org/OAI/2.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" exclude-result-prefixes="xsl dnet oai" version="2.0">
18
                        <xsl:output encoding="UTF-8" method="xml" omit-xml-declaration="yes"/>
19
                        <xsl:template match="/">
20
                            <xsl:for-each select="//record">
21
                                <dc:resource xmlns:dc="http://datacite.org/schema/kernel-4" xsi:schemaLocation="http://datacite.org/schema/kernel-4 http://schema.datacite.org/meta/kernel-4.3/metadata.xsd">
22
                                    <xsl:variable name="bestRights" select="./bestRights"/>
23
                                    <xsl:variable name="type" select="./type"/>
24
                                    <!-- <dc:title>
25
                                        <xsl:value-of select="./title"/>
26
                                    </dc:title>
27
                                    <xsl:for-each select="./creators/creator">
28
                                        <dc:creator>
29
                                            <xsl:value-of select="."/>
30
                                        </dc:creator>
31
                                    </xsl:for-each>
32
                                    <xsl:for-each select="./contributors/contributor">
33
                                        <dc:contributor>
34
                                            <xsl:value-of select="."/>
35
                                        </dc:contributor>
36
                                    </xsl:for-each>
37
                                    <dc:publisher>
38
                                        <xsl:value-of select="./publisher"/>
39
                                    </dc:publisher>
40
                                    <dc:description>
41
                                        <xsl:value-of select="./abstract"/>
42
                                    </dc:description>
43
                                    <xsl:for-each select="./subjects/subject">
44
                                        <dc:subject>
45
                                            <xsl:value-of select="."/>
46
                                        </dc:subject>
47
                                    </xsl:for-each>
48
                                    <dc:date>
49
                                        <xsl:value-of select="./date"/>
50
                                    </dc:date>
51
                                    <dc:language>
52
                                        <xsl:value-of select="./language"/>
53
                                    </dc:language>
54
                                    <dc:type>
55
                                        <xsl:choose>
56
                                            <xsl:when test="$type = 'Conference object'">info:eu-repo/semantics/conferenceObject</xsl:when>
57
                                            <xsl:when test="$type = 'Report'">info:eu-repo/semantics/report</xsl:when>
58
                                            <xsl:when test="$type = 'Article'">info:eu-repo/semantics/article</xsl:when>
59
                                            <xsl:when test="$type = 'Other'">info:eu-repo/semantics/other</xsl:when>
60
                                            <xsl:when test="$type = 'Part of book or chapter of book'">info:eu-repo/semantics/bookPart</xsl:when>
61
                                            <xsl:when test="$type = 'Book'">info:eu-repo/semantics/book</xsl:when>
62
                                            <xsl:when test="$type = 'Bachelor thesis'">info:eu-repo/semantics/bachelorThesis</xsl:when>
63
                                            <xsl:when test="$type = 'Doctoral thesis'">info:eu-repo/semantics/doctoralThesis</xsl:when>
64
                                            <xsl:when test="$type = 'Patent'">info:eu-repo/semantics/patent</xsl:when>
65
                                            <xsl:when test="$type = 'Master thesis'">info:eu-repo/semantics/masterThesis</xsl:when>
66
                                            <xsl:otherwise>info:eu-repo/semantics/other</xsl:otherwise>
67
                                        </xsl:choose>
68
                                    </dc:type>
69
                                    <dc:type>
70
                                        <xsl:value-of select="$type"/>
71
                                    </dc:type>
72
                                    <dc:rights>
73
                                        <xsl:choose>
74
                                            <xsl:when test="$bestRights = 'Closed Access'">info:eu-repo/semantics/closedAccess</xsl:when>
75
                                            <xsl:when test="$bestRights = 'Open Access'">info:eu-repo/semantics/openAccess</xsl:when>
76
                                            <xsl:when test="$bestRights = 'Restricted'">info:eu-repo/semantics/restrictedAccess</xsl:when>
77
                                            <xsl:otherwise>info:eu-repo/semantics/restrictedAccess</xsl:otherwise>
78
                                        </xsl:choose>
79
                                    </dc:rights>
80
                                    <dc:identifier>
81
                                        <xsl:value-of select="concat('people:',./identifier)"/>
82
                                    </dc:identifier>
83
                                    <xsl:for-each select="./urls/url[@rights = $bestRights]">
84
                                        <dc:identifier>
85
                                            <xsl:value-of select="."/>
86
                                        </dc:identifier>
87
                                    </xsl:for-each>
88
                                    <xsl:for-each select="./dois/doi">
89
                                        <dc:identifier>
90
                                            <xsl:value-of select="concat('info:doi:',.)"/>
91
                                        </dc:identifier>
92
                                    </xsl:for-each>
93
                                    <xsl:for-each select="./projects/project">
94
                                        <dc:relation>
95
                                            <xsl:value-of select="concat('info:eu-repo/grantAgreement/',./funder,'/',./program,'/',./code,'/',./jurisdiction,'/',./name,'/',./acronym)"/>
96
                                        </dc:relation>
97
                                    </xsl:for-each>
98
                                    -->
99
                                </dc:resource>
100
                            </xsl:for-each>
101
                        </xsl:template>
102
                    </xsl:stylesheet>
103
                </CODE>
104
            </SCRIPT>
105
        </CONFIGURATION>
106
        <STATUS/>
107
        <SECURITY_PARAMETERS>SECURITY_PARAMETERS</SECURITY_PARAMETERS>
108
    </BODY>
109
</RESOURCE_PROFILE>
(2-2/3)