3 <xsl:stylesheet version="1.0"
4 xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
6 <xsl:import href="common-referencedata.xsl"/>
8 <!-- Index handling reference data -->
10 <xsl:template match="BlockAtoms">
11 <xsl:if test="Sequence[@Name='Input']">
13 <xsl:call-template name="SequenceAsHorizontalTable">
14 <xsl:with-param name="root" select="Sequence[@Name='Input']"/>
23 <xsl:for-each select="Block">
25 <td><xsl:value-of select="Sequence[@Name='Atoms']/Int[@Name='Length']"/></td>
27 <xsl:call-template name="SequenceAsCSV">
28 <xsl:with-param name="root" select="Sequence[@Name='Atoms']"/>
36 <xsl:template match="IndexMapping">
37 <h2><xsl:value-of select="@Name"/></h2>
39 <xsl:call-template name="SequenceAsHorizontalTable">
40 <xsl:with-param name="root" select="Sequence[@Name='Input']"/>
46 <xsl:if test="Block/Int[@Name='MapId']">
52 <xsl:for-each select="Block">
54 <td><xsl:value-of select="Int[@Name='RefId']"/></td>
55 <xsl:if test="Int[@Name='MapId']">
56 <td><xsl:value-of select="Int[@Name='MapId']"/></td>
58 <td><xsl:value-of select="Sequence[@Name='Atoms']/Int[@Name='Length']"/></td>
60 <xsl:call-template name="SequenceAsCSV">
61 <xsl:with-param name="root" select="Sequence[@Name='Atoms']"/>
69 <xsl:template match="OrgIdGroups">
70 <h2>Groups: <xsl:value-of select="@Name"/></h2>
74 <td><xsl:value-of select="Int[@Name='GroupCount']"/></td>
79 <xsl:call-template name="SequenceAsCSV">
80 <xsl:with-param name="root" select="Sequence[@Name='OrgId']"/>
87 <!-- Position calculation reference data -->
89 <xsl:template match="InitializedPositions">
90 <h2>Initialized Positions</h2>
91 <xsl:apply-templates />
94 <xsl:template match="EvaluatedPositions">
95 <h2>Evaluated for <xsl:value-of select="@Name"/></h2>
96 <xsl:apply-templates />
99 <xsl:template match="Positions">
100 <xsl:if test="@Name">
101 <h3><xsl:value-of select="@Name"/></h3>
107 <xsl:value-of select="Int[@Name='Count']"/>
108 (type: <xsl:value-of select="String[@Name='Type']"/>)
114 <xsl:call-template name="SequenceAsCSV">
115 <xsl:with-param name="root" select="Sequence[@Name='Block']"/>
125 <xsl:if test="Position/Vector[@Name='Coordinates']">
128 <xsl:if test="Position/Vector[@Name='Velocity']">
131 <xsl:if test="Position/Vector[@Name='Force']">
135 <xsl:for-each select="Position">
137 <td><xsl:value-of select="Int[@Name='RefId']"/></td>
138 <td><xsl:value-of select="Sequence[@Name='Atoms']/Int[@Name='Length']"/></td>
140 <xsl:call-template name="SequenceAsCSV">
141 <xsl:with-param name="root" select="Sequence[@Name='Atoms']"/>
144 <xsl:if test="Vector[@Name='Coordinates']">
146 <xsl:apply-templates select="Vector[@Name='Coordinates']"/>
149 <xsl:if test="Vector[@Name='Velocity']">
151 <xsl:apply-templates select="Vector[@Name='Velocity']"/>
154 <xsl:if test="Vector[@Name='Force']">
156 <xsl:apply-templates select="Vector[@Name='Force']"/>
164 <!-- Selection reference data -->
166 <xsl:key name="SelectionName" match="ParsedSelections/ParsedSelection" use="@Name"/>
168 <xsl:template match="ParsedSelections">
169 <h2>Parsed Selections</h2>
174 <xsl:if test="*/String[@Name='Name']">
180 <xsl:for-each select="*">
182 <td><xsl:value-of select="@Name"/></td>
183 <td><xsl:value-of select="String[@Name='Input']"/></td>
184 <xsl:if test="String[@Name='Name']">
185 <td><xsl:value-of select="String[@Name='Name']"/></td>
187 <td><xsl:value-of select="String[@Name='Text']"/></td>
188 <td><xsl:value-of select="Bool[@Name='Dynamic']"/></td>
194 <xsl:template match="CompiledSelections">
195 <h2>Compiled Selections</h2>
196 <xsl:apply-templates />
199 <xsl:template match="EvaluatedSelections">
200 <h2>Evaluated for <xsl:value-of select="@Name"/></h2>
201 <xsl:apply-templates />
204 <xsl:template match="Selection">
205 <h3><xsl:value-of select="@Name"/></h3>
207 <xsl:if test="String[@Name='Name']">
210 <td><xsl:value-of select="String[@Name='Name']"/></td>
214 <td>Selection text:</td>
216 <xsl:value-of select="key('SelectionName', @Name)/String[@Name='Text']"/>
219 <xsl:if test="Sequence[@Name='Atoms']">
221 <td>Atoms (<xsl:value-of select="Sequence[@Name='Atoms']/Int[@Name='Length']"/>):</td>
223 <xsl:call-template name="SequenceAsCSV">
224 <xsl:with-param name="root" select="Sequence[@Name='Atoms']"/>
230 <xsl:apply-templates select="Sequence[@Name='Positions']"/>
233 <xsl:template match="Selection/Sequence[@Name='Positions']">
235 Positions (count: <xsl:value-of select="Int[@Name='Length']"/>):
238 <xsl:if test="Position/Sequence[@Name='Atoms']">
242 <xsl:if test="Position/Int[@Name='RefId']">
246 <xsl:if test="Position/Vector[@Name='Coordinates']">
249 <xsl:if test="Position/Real[@Name='Mass']">
252 <xsl:if test="Position/Real[@Name='Charge']">
256 <xsl:for-each select="Position">
258 <xsl:if test="Sequence[@Name='Atoms']">
259 <td><xsl:value-of select="Sequence[@Name='Atoms']/Int[@Name='Length']"/></td>
261 <xsl:call-template name="SequenceAsCSV">
262 <xsl:with-param name="root" select="Sequence[@Name='Atoms']"/>
266 <xsl:if test="Int[@Name='RefId']">
267 <td><xsl:value-of select="Int[@Name='RefId']"/></td>
268 <td><xsl:value-of select="Int[@Name='MappedId']"/></td>
270 <xsl:if test="Vector[@Name='Coordinates']">
272 <xsl:apply-templates select="Vector[@Name='Coordinates']"/>
275 <xsl:if test="Real[@Name='Mass']">
276 <td><xsl:value-of select="Real[@Name='Mass']"/></td>
278 <xsl:if test="Real[@Name='Charge']">
279 <td><xsl:value-of select="Real[@Name='Charge']"/></td>