1 |
10046
|
mecum
|
<?xml version="1.0"?>
|
2 |
|
|
<xsl:stylesheet
|
3 |
10056
|
mecum
|
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
4 |
|
|
xmlns:gmd="http://www.isotc211.org/2005/gmd"
|
5 |
|
|
xmlns:gco="http://www.isotc211.org/2005/gco"
|
6 |
|
|
version="1.0">
|
7 |
10046
|
mecum
|
|
8 |
10059
|
mecum
|
<xsl:import href="iso-md.xsl"/>
|
9 |
10056
|
mecum
|
<xsl:import href="iso-ci.xsl"/>
|
10 |
|
|
<xsl:import href="iso-ex.xsl"/>
|
11 |
10059
|
mecum
|
<xsl:import href="iso-gco.xsl"/>
|
12 |
|
|
<xsl:import href="iso-gmd.xsl"/>
|
13 |
|
|
<xsl:import href="iso-gml.xsl"/>
|
14 |
|
|
<xsl:import href="iso-gmx.xsl"/>
|
15 |
10046
|
mecum
|
|
16 |
10056
|
mecum
|
<xsl:output method="html" encoding="UTF-8"
|
17 |
|
|
doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
|
18 |
|
|
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
|
19 |
|
|
indent="yes" />
|
20 |
10049
|
mecum
|
|
21 |
10056
|
mecum
|
<!-- TODO: Figure out how to set the output method to get what I want -->
|
22 |
|
|
<!-- TODO: ^ Figure out what I want to output -->
|
23 |
|
|
<!-- TODO: Figuer out what this match statement should have in it -->
|
24 |
|
|
<!-- TODO: Cover gmd:identificationInfo/SV_ServiceIdentification -->
|
25 |
|
|
|
26 |
|
|
<xsl:template match="*[local-name()='MD_Metadata'] | *[local-name()='MI_Metadata']">
|
27 |
|
|
<form class="form-horizontal">
|
28 |
|
|
<div class="control-group entity">
|
29 |
|
|
<h4>General</h4>
|
30 |
|
|
<!-- fileIdentifier 1:1 -->
|
31 |
|
|
<div class="control-group">
|
32 |
|
|
<label class="control-label">Identifier</label>
|
33 |
|
|
<div class="controls">
|
34 |
|
|
<div class="controls-well">
|
35 |
|
|
<xsl:value-of select="//gmd:fileIdentifier/gco:CharacterString/text()" />
|
36 |
10049
|
mecum
|
</div>
|
37 |
10056
|
mecum
|
</div>
|
38 |
|
|
</div>
|
39 |
10046
|
mecum
|
|
40 |
10056
|
mecum
|
<!-- TODO: language 1:1 -->
|
41 |
|
|
<!-- TODO: characterSet 1:1 -->
|
42 |
|
|
|
43 |
|
|
<!-- Parent Identifier 1:1 conditional -->
|
44 |
|
|
<xsl:if test="//gmd:parentIdentifier">
|
45 |
|
|
<div class="control-group">
|
46 |
|
|
<label class="control-label">Parent Identifier</label>
|
47 |
|
|
<div class="controls">
|
48 |
|
|
<div class="controls-well">
|
49 |
|
|
<xsl:value-of select="//gmd:parentIdentifier/gco:CharacterString/text()" />
|
50 |
|
|
</div>
|
51 |
10046
|
mecum
|
</div>
|
52 |
10056
|
mecum
|
</div>
|
53 |
|
|
</xsl:if>
|
54 |
10046
|
mecum
|
|
55 |
10056
|
mecum
|
<!-- TODO: hierarchyLevel 0:inf -->
|
56 |
|
|
<!-- TODO: hierarchyLevelName 0:inf -->
|
57 |
10046
|
mecum
|
|
58 |
10056
|
mecum
|
<!-- Alternate identifier(s) 0:inf-->
|
59 |
|
|
<!-- gmd:identifier is an optional aprt of the CI_Citation element -->
|
60 |
|
|
<xsl:for-each select="//gmd:identificationInfo/gmd:MD_DataIdentification/gmd:citation/gmd:CI_Citation/gmd:identifier">
|
61 |
|
|
<div class="control-group">
|
62 |
|
|
<label class="control-label">Cited Identifier</label>
|
63 |
|
|
<div class="controls">
|
64 |
|
|
<div class="controls-well">
|
65 |
|
|
<xsl:apply-templates />
|
66 |
|
|
</div>
|
67 |
10046
|
mecum
|
</div>
|
68 |
10056
|
mecum
|
</div>
|
69 |
|
|
</xsl:for-each>
|
70 |
10046
|
mecum
|
|
71 |
10056
|
mecum
|
<!-- Abstract 1:inf-->
|
72 |
|
|
<xsl:for-each select="//gmd:identificationInfo/gmd:MD_DataIdentification/gmd:abstract">
|
73 |
|
|
<div class="control-group">
|
74 |
|
|
<label class="control-label">Abstract</label>
|
75 |
|
|
<div class="controls">
|
76 |
|
|
<div class="controls-well">
|
77 |
|
|
<xsl:apply-templates />
|
78 |
|
|
</div>
|
79 |
|
|
</div>
|
80 |
|
|
</div>
|
81 |
|
|
</xsl:for-each>
|
82 |
10046
|
mecum
|
|
83 |
10056
|
mecum
|
<!-- Topic Categories -->
|
84 |
|
|
<xsl:if test="//gmd:topicCategory">
|
85 |
|
|
<div class="control-group">
|
86 |
|
|
<label class="control-label">Topic Categories</label>
|
87 |
|
|
<div class="controls">
|
88 |
|
|
<div class="controls-well">
|
89 |
10059
|
mecum
|
<table class="table table-condensed">
|
90 |
|
|
<thead>
|
91 |
|
|
<tr>
|
92 |
|
|
<th>Topic</th>
|
93 |
|
|
</tr>
|
94 |
|
|
</thead>
|
95 |
|
|
<tbody>
|
96 |
|
|
<xsl:for-each select="//gmd:topicCategory">
|
97 |
|
|
<tr>
|
98 |
|
|
<td><xsl:apply-templates /></td>
|
99 |
|
|
</tr>
|
100 |
|
|
</xsl:for-each>
|
101 |
|
|
</tbody>
|
102 |
|
|
</table>
|
103 |
10056
|
mecum
|
</div>
|
104 |
|
|
</div>
|
105 |
|
|
</div>
|
106 |
|
|
</xsl:if>
|
107 |
|
|
|
108 |
|
|
<!-- Keywords
|
109 |
10046
|
mecum
|
|
110 |
10056
|
mecum
|
Each <gmd:descriptiveKeywords> block should have one or more keywords in it
|
111 |
|
|
with one thesaurus. So we render keywords from the same thesaurus together.
|
112 |
|
|
-->
|
113 |
|
|
<xsl:if test="//gmd:descriptiveKeywords">
|
114 |
|
|
<div class="control-group">
|
115 |
|
|
<label class="control-label">Descriptive Keywords</label>
|
116 |
|
|
<div class="controls">
|
117 |
|
|
<div class="controls-well">
|
118 |
|
|
<xsl:for-each select="//gmd:descriptiveKeywords">
|
119 |
|
|
<xsl:apply-templates />
|
120 |
|
|
</xsl:for-each>
|
121 |
|
|
</div>
|
122 |
|
|
</div>
|
123 |
|
|
</div>
|
124 |
|
|
</xsl:if>
|
125 |
|
|
</div>
|
126 |
10046
|
mecum
|
|
127 |
10056
|
mecum
|
<div class="control-group entity">
|
128 |
|
|
<h4>People and Associated Parties</h4>
|
129 |
10046
|
mecum
|
|
130 |
10056
|
mecum
|
<!-- Metadata Contact(s) 1:inf -->
|
131 |
|
|
<div class="control-group">
|
132 |
|
|
<label class="control-label">Metadata Contact(s)</label>
|
133 |
|
|
<div class="controls">
|
134 |
|
|
<div class="controls-well">
|
135 |
|
|
<xsl:for-each select="//gmd:contact">
|
136 |
|
|
<xsl:apply-templates />
|
137 |
|
|
</xsl:for-each>
|
138 |
10046
|
mecum
|
</div>
|
139 |
10056
|
mecum
|
</div>
|
140 |
|
|
</div>
|
141 |
10046
|
mecum
|
|
142 |
10056
|
mecum
|
<!-- Data Set Contact(s) -->
|
143 |
|
|
<div class="control-group">
|
144 |
|
|
<label class="control-label">Data Set Contacts</label>
|
145 |
|
|
<div class="controls">
|
146 |
|
|
<div class="controls-well">
|
147 |
|
|
<xsl:apply-templates select="//gmd:identificationInfo/gmd:MD_DataIdentification/gmd:pointOfContact" />
|
148 |
10046
|
mecum
|
</div>
|
149 |
10056
|
mecum
|
</div>
|
150 |
|
|
</div>
|
151 |
10046
|
mecum
|
|
152 |
10056
|
mecum
|
<!-- Cited responsible parties-->
|
153 |
|
|
<div class="control-group">
|
154 |
|
|
<label class="control-label">Associated Parties</label>
|
155 |
|
|
<div class="controls">
|
156 |
|
|
<div class="controls-well">
|
157 |
|
|
<xsl:apply-templates select="//gmd:identificationInfo/gmd:MD_DataIdentification/gmd:citation/gmd:CI_Citation/gmd:citedResponsibleParty" />
|
158 |
10046
|
mecum
|
</div>
|
159 |
10056
|
mecum
|
</div>
|
160 |
|
|
</div>
|
161 |
|
|
</div>
|
162 |
10046
|
mecum
|
|
163 |
10056
|
mecum
|
<!-- TODO: otherEntities? -->
|
164 |
10046
|
mecum
|
|
165 |
10056
|
mecum
|
<!-- Extent (geographic, temporal, vertical) -->
|
166 |
|
|
<xsl:for-each select="//gmd:identificationInfo/gmd:MD_DataIdentification/gmd:extent">
|
167 |
10057
|
mecum
|
<xsl:apply-templates />
|
168 |
10056
|
mecum
|
</xsl:for-each>
|
169 |
10046
|
mecum
|
|
170 |
10056
|
mecum
|
<!-- TODO Methods -->
|
171 |
10046
|
mecum
|
|
172 |
10056
|
mecum
|
</form>
|
173 |
|
|
</xsl:template>
|
174 |
10046
|
mecum
|
|
175 |
10056
|
mecum
|
<!-- General, high-level templates -->
|
176 |
10046
|
mecum
|
|
177 |
10056
|
mecum
|
<!-- TODO: Figure out how to do this: I want to capture the scenario where
|
178 |
|
|
an element like gmd:individualName has on child gco:CharacterString or
|
179 |
10059
|
mecum
|
equivalent but has a nilReason attribute. -->
|
180 |
|
|
<xsl:template match="*[not(*) and ./@nilReason]">
|
181 |
|
|
nilReason!
|
182 |
10056
|
mecum
|
<xsl:value-of select="@nilReason" />
|
183 |
|
|
</xsl:template>
|
184 |
10046
|
mecum
|
</xsl:stylesheet>
|