docbook_xsl_wrapper 0.1.2 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +2 -0
- data/CHANGELOG +41 -0
- data/README.md +9 -17
- data/bin/docbook_xsl_wrapper +9 -14
- data/docbook_xsl_wrapper.gemspec +8 -7
- data/lib/docbook_xsl_wrapper.rb +24 -1
- data/lib/docbook_xsl_wrapper/epub.rb +124 -122
- data/lib/docbook_xsl_wrapper/options.rb +1 -1
- data/lib/docbook_xsl_wrapper/validate.rb +22 -0
- data/lib/docbook_xsl_wrapper/version.rb +1 -1
- data/schema/docbookxi.rng +18654 -0
- data/spec/docbook_xsl_wrapper/validate_spec.rb +64 -0
- data/xsl/AUTHORS +4 -0
- data/xsl/COPYING +48 -0
- data/xsl/REVISION +1 -0
- data/xsl/VERSION.xsl +115 -0
- data/xsl/common/addns.xsl +124 -0
- data/xsl/common/af.xml +1272 -0
- data/xsl/common/am.xml +1272 -0
- data/xsl/common/ar.xml +1272 -0
- data/xsl/common/as.xml +703 -0
- data/xsl/common/ast.xml +703 -0
- data/xsl/common/autoidx-kimber.xsl +45 -0
- data/xsl/common/autoidx-kosek.xsl +155 -0
- data/xsl/common/az.xml +715 -0
- data/xsl/common/bg.xml +767 -0
- data/xsl/common/bn.xml +1272 -0
- data/xsl/common/bn_in.xml +703 -0
- data/xsl/common/bs.xml +705 -0
- data/xsl/common/ca.xml +703 -0
- data/xsl/common/charmap.xsl +222 -0
- data/xsl/common/common.xsl +2129 -0
- data/xsl/common/cs.xml +743 -0
- data/xsl/common/cy.xml +1288 -0
- data/xsl/common/da.xml +707 -0
- data/xsl/common/de.xml +709 -0
- data/xsl/common/el.xml +772 -0
- data/xsl/common/en.xml +1272 -0
- data/xsl/common/entities.ent +67 -0
- data/xsl/common/eo.xml +1272 -0
- data/xsl/common/es.xml +719 -0
- data/xsl/common/et.xml +1272 -0
- data/xsl/common/eu.xml +1272 -0
- data/xsl/common/fa.xml +703 -0
- data/xsl/common/fi.xml +713 -0
- data/xsl/common/fr.xml +733 -0
- data/xsl/common/ga.xml +1272 -0
- data/xsl/common/gentext.xsl +855 -0
- data/xsl/common/gl.xml +1272 -0
- data/xsl/common/gu.xml +703 -0
- data/xsl/common/he.xml +1272 -0
- data/xsl/common/hi.xml +703 -0
- data/xsl/common/hr.xml +705 -0
- data/xsl/common/hu.xml +721 -0
- data/xsl/common/id.xml +1272 -0
- data/xsl/common/insertfile.xsl +113 -0
- data/xsl/common/is.xml +715 -0
- data/xsl/common/it.xml +1272 -0
- data/xsl/common/ja.xml +703 -0
- data/xsl/common/ka.xml +743 -0
- data/xsl/common/kn.xml +1272 -0
- data/xsl/common/ko.xml +1272 -0
- data/xsl/common/ky.xml +775 -0
- data/xsl/common/l10n.dtd +64 -0
- data/xsl/common/l10n.xml +78 -0
- data/xsl/common/l10n.xsl +598 -0
- data/xsl/common/la.xml +1272 -0
- data/xsl/common/labels.xsl +933 -0
- data/xsl/common/lt.xml +721 -0
- data/xsl/common/lv.xml +1272 -0
- data/xsl/common/ml.xml +703 -0
- data/xsl/common/mn.xml +773 -0
- data/xsl/common/mr.xml +703 -0
- data/xsl/common/nb.xml +1272 -0
- data/xsl/common/nds.xml +709 -0
- data/xsl/common/nl.xml +703 -0
- data/xsl/common/nn.xml +1272 -0
- data/xsl/common/olink.xsl +1284 -0
- data/xsl/common/or.xml +1272 -0
- data/xsl/common/pa.xml +703 -0
- data/xsl/common/pi.xml +168 -0
- data/xsl/common/pi.xsl +347 -0
- data/xsl/common/pl.xml +721 -0
- data/xsl/common/pt.xml +1272 -0
- data/xsl/common/pt_br.xml +1272 -0
- data/xsl/common/refentry.xsl +1353 -0
- data/xsl/common/ro.xml +1272 -0
- data/xsl/common/ru.xml +769 -0
- data/xsl/common/sk.xml +1272 -0
- data/xsl/common/sl.xml +1272 -0
- data/xsl/common/sq.xml +1272 -0
- data/xsl/common/sr.xml +763 -0
- data/xsl/common/sr_Latn.xml +722 -0
- data/xsl/common/subtitles.xsl +181 -0
- data/xsl/common/sv.xml +707 -0
- data/xsl/common/ta.xml +703 -0
- data/xsl/common/table.xsl +515 -0
- data/xsl/common/targetdatabase.dtd +49 -0
- data/xsl/common/targets.xsl +338 -0
- data/xsl/common/te.xml +703 -0
- data/xsl/common/th.xml +1272 -0
- data/xsl/common/titles.xsl +850 -0
- data/xsl/common/tl.xml +1272 -0
- data/xsl/common/tr.xml +709 -0
- data/xsl/common/uk.xml +769 -0
- data/xsl/common/ur.xml +705 -0
- data/xsl/common/utility.xsl +291 -0
- data/xsl/common/vi.xml +1272 -0
- data/xsl/common/xh.xml +1272 -0
- data/xsl/common/zh.xml +703 -0
- data/xsl/common/zh_cn.xml +703 -0
- data/xsl/common/zh_tw.xml +703 -0
- data/xsl/epub/docbook.xsl +1769 -0
- data/xsl/epub3/chunk.xsl +30 -0
- data/xsl/epub3/docbook-epub.css.xml +142 -0
- data/xsl/epub3/docbook.xsl +20 -0
- data/xsl/epub3/epub3-chunk-mods.xsl +52 -0
- data/xsl/epub3/epub3-element-mods.xsl +2533 -0
- data/xsl/epub3/titlepage.templates.xml +712 -0
- data/xsl/epub3/titlepage.templates.xsl +3842 -0
- data/xsl/lib/lib.xsl +533 -0
- data/xsl/xhtml/admon.xsl +142 -0
- data/xsl/xhtml/annotations.xsl +160 -0
- data/xsl/xhtml/autoidx.xsl +831 -0
- data/xsl/xhtml/autotoc.xsl +706 -0
- data/xsl/xhtml/biblio-iso690.xsl +1302 -0
- data/xsl/xhtml/biblio.xsl +1371 -0
- data/xsl/xhtml/block.xsl +584 -0
- data/xsl/xhtml/callout.xsl +210 -0
- data/xsl/xhtml/chunk-code.xsl +675 -0
- data/xsl/xhtml/chunk-common.xsl +1627 -0
- data/xsl/xhtml/chunker.xsl +317 -0
- data/xsl/xhtml/component.xsl +440 -0
- data/xsl/xhtml/division.xsl +214 -0
- data/xsl/xhtml/ebnf.xsl +331 -0
- data/xsl/xhtml/footnote.xsl +346 -0
- data/xsl/xhtml/formal.xsl +496 -0
- data/xsl/xhtml/glossary.xsl +602 -0
- data/xsl/xhtml/graphics.xsl +1537 -0
- data/xsl/xhtml/html-rtf.xsl +321 -0
- data/xsl/xhtml/html.xsl +690 -0
- data/xsl/xhtml/htmltbl.xsl +102 -0
- data/xsl/xhtml/index.xsl +264 -0
- data/xsl/xhtml/info.xsl +48 -0
- data/xsl/xhtml/inline.xsl +1508 -0
- data/xsl/xhtml/its.xsl +109 -0
- data/xsl/xhtml/keywords.xsl +38 -0
- data/xsl/xhtml/lists.xsl +1227 -0
- data/xsl/xhtml/math.xsl +286 -0
- data/xsl/xhtml/param.xsl +449 -0
- data/xsl/xhtml/pi.xsl +1237 -0
- data/xsl/xhtml/qandaset.xsl +440 -0
- data/xsl/xhtml/refentry.xsl +307 -0
- data/xsl/xhtml/sections.xsl +564 -0
- data/xsl/xhtml/synop.xsl +1623 -0
- data/xsl/xhtml/table.xsl +1179 -0
- data/xsl/xhtml/task.xsl +76 -0
- data/xsl/xhtml/titlepage.templates.xsl +4005 -0
- data/xsl/xhtml/titlepage.xsl +1108 -0
- data/xsl/xhtml/toc.xsl +334 -0
- data/xsl/xhtml/verbatim.xsl +389 -0
- data/xsl/xhtml/xref.xsl +1268 -0
- data/xsl/xhtml5/docbook.xsl +22 -0
- data/xsl/xhtml5/html5-chunk-mods.xsl +112 -0
- data/xsl/xhtml5/html5-element-mods.xsl +791 -0
- data/xsl/xhtml5/xhtml-docbook.xsl +531 -0
- metadata +207 -27
- data/.rvmrc +0 -48
- data/xslt/obfuscate.xsl +0 -12
data/xsl/xhtml/synop.xsl
ADDED
|
@@ -0,0 +1,1623 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="ASCII"?>
|
|
2
|
+
<!--This file was created automatically by html2xhtml-->
|
|
3
|
+
<!--from the HTML stylesheets.-->
|
|
4
|
+
<xsl:stylesheet exclude-result-prefixes="d"
|
|
5
|
+
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:d="http://docbook.org/ns/docbook"
|
|
6
|
+
xmlns="http://www.w3.org/1999/xhtml" version="1.0">
|
|
7
|
+
|
|
8
|
+
<!-- ********************************************************************
|
|
9
|
+
$Id: synop.xsl 9829 2013-11-05 20:07:15Z bobstayton $
|
|
10
|
+
********************************************************************
|
|
11
|
+
|
|
12
|
+
This file is part of the XSL DocBook Stylesheet distribution.
|
|
13
|
+
See ../README or http://docbook.sf.net/release/xsl/current/ for
|
|
14
|
+
copyright and other information.
|
|
15
|
+
|
|
16
|
+
******************************************************************** -->
|
|
17
|
+
|
|
18
|
+
<!-- ==================================================================== -->
|
|
19
|
+
|
|
20
|
+
<!-- synopsis is in verbatim -->
|
|
21
|
+
|
|
22
|
+
<!-- ==================================================================== -->
|
|
23
|
+
|
|
24
|
+
<xsl:template match="d:cmdsynopsis">
|
|
25
|
+
<div>
|
|
26
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
27
|
+
<p>
|
|
28
|
+
<xsl:call-template name="id.attribute">
|
|
29
|
+
<xsl:with-param name="conditional" select="0"/>
|
|
30
|
+
</xsl:call-template>
|
|
31
|
+
<xsl:choose>
|
|
32
|
+
<xsl:when test="..//processing-instruction('dbcmdlist')">
|
|
33
|
+
<!-- * Placing a dbcmdlist PI as a child of a particular element -->
|
|
34
|
+
<!-- * creates a hyperlinked list of all cmdsynopsis instances -->
|
|
35
|
+
<!-- * that are descendants of that element; so for any -->
|
|
36
|
+
<!-- * cmdsynopsis that is a descendant of an element containing -->
|
|
37
|
+
<!-- * a dbcmdlist PI, we need to output an a@id instance so that -->
|
|
38
|
+
<!-- * we will have something to link to -->
|
|
39
|
+
<xsl:call-template name="anchor">
|
|
40
|
+
<xsl:with-param name="conditional" select="0"/>
|
|
41
|
+
</xsl:call-template>
|
|
42
|
+
</xsl:when>
|
|
43
|
+
<xsl:otherwise>
|
|
44
|
+
<xsl:call-template name="anchor">
|
|
45
|
+
<xsl:with-param name="conditional" select="1"/>
|
|
46
|
+
</xsl:call-template>
|
|
47
|
+
</xsl:otherwise>
|
|
48
|
+
</xsl:choose>
|
|
49
|
+
<xsl:apply-templates/>
|
|
50
|
+
</p>
|
|
51
|
+
</div>
|
|
52
|
+
</xsl:template>
|
|
53
|
+
|
|
54
|
+
<xsl:template match="d:cmdsynopsis/d:command">
|
|
55
|
+
<br/>
|
|
56
|
+
<xsl:call-template name="inline.monoseq"/>
|
|
57
|
+
<xsl:text> </xsl:text>
|
|
58
|
+
</xsl:template>
|
|
59
|
+
|
|
60
|
+
<xsl:template match="d:cmdsynopsis/d:command[1]" priority="2">
|
|
61
|
+
<xsl:call-template name="inline.monoseq"/>
|
|
62
|
+
<xsl:text> </xsl:text>
|
|
63
|
+
</xsl:template>
|
|
64
|
+
|
|
65
|
+
<xsl:template match="d:group|d:arg" name="group-or-arg">
|
|
66
|
+
<xsl:variable name="choice" select="@choice"/>
|
|
67
|
+
<xsl:variable name="rep" select="@rep"/>
|
|
68
|
+
<xsl:variable name="sepchar">
|
|
69
|
+
<xsl:choose>
|
|
70
|
+
<xsl:when test="ancestor-or-self::*/@sepchar">
|
|
71
|
+
<xsl:value-of select="ancestor-or-self::*/@sepchar"/>
|
|
72
|
+
</xsl:when>
|
|
73
|
+
<xsl:otherwise>
|
|
74
|
+
<xsl:text> </xsl:text>
|
|
75
|
+
</xsl:otherwise>
|
|
76
|
+
</xsl:choose>
|
|
77
|
+
</xsl:variable>
|
|
78
|
+
|
|
79
|
+
<xsl:if test="preceding-sibling::*">
|
|
80
|
+
<xsl:value-of select="$sepchar"/>
|
|
81
|
+
</xsl:if>
|
|
82
|
+
<xsl:choose>
|
|
83
|
+
<xsl:when test="$choice='plain'">
|
|
84
|
+
<xsl:value-of select="$arg.choice.plain.open.str"/>
|
|
85
|
+
</xsl:when>
|
|
86
|
+
<xsl:when test="$choice='req'">
|
|
87
|
+
<xsl:value-of select="$arg.choice.req.open.str"/>
|
|
88
|
+
</xsl:when>
|
|
89
|
+
<xsl:when test="$choice='opt'">
|
|
90
|
+
<xsl:value-of select="$arg.choice.opt.open.str"/>
|
|
91
|
+
</xsl:when>
|
|
92
|
+
<xsl:otherwise>
|
|
93
|
+
<xsl:value-of select="$arg.choice.def.open.str"/>
|
|
94
|
+
</xsl:otherwise>
|
|
95
|
+
</xsl:choose>
|
|
96
|
+
<xsl:apply-templates/>
|
|
97
|
+
<xsl:choose>
|
|
98
|
+
<xsl:when test="$rep='repeat'">
|
|
99
|
+
<xsl:value-of select="$arg.rep.repeat.str"/>
|
|
100
|
+
</xsl:when>
|
|
101
|
+
<xsl:when test="$rep='norepeat'">
|
|
102
|
+
<xsl:value-of select="$arg.rep.norepeat.str"/>
|
|
103
|
+
</xsl:when>
|
|
104
|
+
<xsl:otherwise>
|
|
105
|
+
<xsl:value-of select="$arg.rep.def.str"/>
|
|
106
|
+
</xsl:otherwise>
|
|
107
|
+
</xsl:choose>
|
|
108
|
+
<xsl:choose>
|
|
109
|
+
<xsl:when test="$choice='plain'">
|
|
110
|
+
<xsl:value-of select="$arg.choice.plain.close.str"/>
|
|
111
|
+
</xsl:when>
|
|
112
|
+
<xsl:when test="$choice='req'">
|
|
113
|
+
<xsl:value-of select="$arg.choice.req.close.str"/>
|
|
114
|
+
</xsl:when>
|
|
115
|
+
<xsl:when test="$choice='opt'">
|
|
116
|
+
<xsl:value-of select="$arg.choice.opt.close.str"/>
|
|
117
|
+
</xsl:when>
|
|
118
|
+
<xsl:otherwise>
|
|
119
|
+
<xsl:value-of select="$arg.choice.def.close.str"/>
|
|
120
|
+
</xsl:otherwise>
|
|
121
|
+
</xsl:choose>
|
|
122
|
+
</xsl:template>
|
|
123
|
+
|
|
124
|
+
<xsl:template match="d:group/d:arg">
|
|
125
|
+
<xsl:variable name="choice" select="@choice"/>
|
|
126
|
+
<xsl:variable name="rep" select="@rep"/>
|
|
127
|
+
<xsl:if test="preceding-sibling::*">
|
|
128
|
+
<xsl:value-of select="$arg.or.sep"/>
|
|
129
|
+
</xsl:if>
|
|
130
|
+
<xsl:call-template name="group-or-arg"/>
|
|
131
|
+
</xsl:template>
|
|
132
|
+
|
|
133
|
+
<xsl:template match="d:sbr">
|
|
134
|
+
<br/>
|
|
135
|
+
</xsl:template>
|
|
136
|
+
|
|
137
|
+
<!-- ==================================================================== -->
|
|
138
|
+
|
|
139
|
+
<xsl:template match="d:synopfragmentref">
|
|
140
|
+
<xsl:variable name="target" select="key('id',@linkend)"/>
|
|
141
|
+
<xsl:variable name="snum">
|
|
142
|
+
<xsl:apply-templates select="$target" mode="synopfragment.number"/>
|
|
143
|
+
</xsl:variable>
|
|
144
|
+
<em xmlns:xslo="http://www.w3.org/1999/XSL/Transform">
|
|
145
|
+
<a href="#{@linkend}">
|
|
146
|
+
<xsl:text>(</xsl:text>
|
|
147
|
+
<xsl:value-of select="$snum"/>
|
|
148
|
+
<xsl:text>)</xsl:text>
|
|
149
|
+
</a>
|
|
150
|
+
<xsl:text> </xsl:text>
|
|
151
|
+
<xsl:apply-templates/>
|
|
152
|
+
</em>
|
|
153
|
+
</xsl:template>
|
|
154
|
+
|
|
155
|
+
<xsl:template match="d:synopfragment" mode="synopfragment.number">
|
|
156
|
+
<xsl:number format="1"/>
|
|
157
|
+
</xsl:template>
|
|
158
|
+
|
|
159
|
+
<xsl:template match="d:synopfragment">
|
|
160
|
+
<xsl:variable name="snum">
|
|
161
|
+
<xsl:apply-templates select="." mode="synopfragment.number"/>
|
|
162
|
+
</xsl:variable>
|
|
163
|
+
<!-- You can't introduce another <p> here, because you're
|
|
164
|
+
already in a <p> from cmdsynopsis-->
|
|
165
|
+
<span>
|
|
166
|
+
<xsl:variable name="id">
|
|
167
|
+
<xsl:call-template name="object.id"/>
|
|
168
|
+
</xsl:variable>
|
|
169
|
+
<a id="{$id}">
|
|
170
|
+
<xsl:text>(</xsl:text>
|
|
171
|
+
<xsl:value-of select="$snum"/>
|
|
172
|
+
<xsl:text>)</xsl:text>
|
|
173
|
+
</a>
|
|
174
|
+
<xsl:text> </xsl:text>
|
|
175
|
+
<xsl:apply-templates/>
|
|
176
|
+
</span>
|
|
177
|
+
</xsl:template>
|
|
178
|
+
|
|
179
|
+
<xsl:template match="d:funcsynopsis">
|
|
180
|
+
<xsl:if test="..//processing-instruction('dbfunclist')">
|
|
181
|
+
<!-- * Placing a dbfunclist PI as a child of a particular element -->
|
|
182
|
+
<!-- * creates a hyperlinked list of all funcsynopsis instances that -->
|
|
183
|
+
<!-- * are descendants of that element; so for any funcsynopsis that is -->
|
|
184
|
+
<!-- * a descendant of an element containing a dbfunclist PI, we need -->
|
|
185
|
+
<!-- * to output an a@id instance so that we will have something to -->
|
|
186
|
+
<!-- * link to -->
|
|
187
|
+
<span>
|
|
188
|
+
<xsl:call-template name="id.attribute">
|
|
189
|
+
<xsl:with-param name="conditional" select="0"/>
|
|
190
|
+
</xsl:call-template>
|
|
191
|
+
</span>
|
|
192
|
+
<xsl:call-template name="anchor">
|
|
193
|
+
<xsl:with-param name="conditional" select="0"/>
|
|
194
|
+
</xsl:call-template>
|
|
195
|
+
</xsl:if>
|
|
196
|
+
<xsl:call-template name="informal.object"/>
|
|
197
|
+
</xsl:template>
|
|
198
|
+
|
|
199
|
+
<xsl:template match="d:funcsynopsisinfo">
|
|
200
|
+
<pre>
|
|
201
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
202
|
+
<xsl:call-template name="id.attribute"/>
|
|
203
|
+
<xsl:apply-templates/>
|
|
204
|
+
</pre>
|
|
205
|
+
</xsl:template>
|
|
206
|
+
|
|
207
|
+
<!-- ====================================================================== -->
|
|
208
|
+
<!-- funcprototype -->
|
|
209
|
+
<!--
|
|
210
|
+
|
|
211
|
+
funcprototype ::= (funcdef,
|
|
212
|
+
(void|varargs|paramdef+))
|
|
213
|
+
|
|
214
|
+
funcdef ::= (#PCDATA|type|replaceable|function)*
|
|
215
|
+
|
|
216
|
+
paramdef ::= (#PCDATA|type|replaceable|parameter|funcparams)*
|
|
217
|
+
-->
|
|
218
|
+
|
|
219
|
+
<xsl:template match="d:funcprototype">
|
|
220
|
+
<xsl:variable name="html-style">
|
|
221
|
+
<xsl:call-template name="pi.dbhtml_funcsynopsis-style">
|
|
222
|
+
<xsl:with-param name="node" select="ancestor::d:funcsynopsis/descendant-or-self::*"/>
|
|
223
|
+
</xsl:call-template>
|
|
224
|
+
</xsl:variable>
|
|
225
|
+
|
|
226
|
+
<xsl:variable name="style">
|
|
227
|
+
<xsl:choose>
|
|
228
|
+
<xsl:when test="$html-style != ''">
|
|
229
|
+
<xsl:value-of select="$html-style"/>
|
|
230
|
+
</xsl:when>
|
|
231
|
+
<xsl:otherwise>
|
|
232
|
+
<xsl:value-of select="$funcsynopsis.style"/>
|
|
233
|
+
</xsl:otherwise>
|
|
234
|
+
</xsl:choose>
|
|
235
|
+
</xsl:variable>
|
|
236
|
+
|
|
237
|
+
<!-- * 2008-02-17. the code no longer relies on the funcsynopsis.tabular.threshold -->
|
|
238
|
+
<!-- * param at all (the stuff below has been commented out since mid -->
|
|
239
|
+
<!-- * 2006), so I completely removed the funcsynopsis.tabular.threshold param -->
|
|
240
|
+
<!-- * .. MikeSmith -->
|
|
241
|
+
<!--
|
|
242
|
+
<xsl:variable name="tabular-p"
|
|
243
|
+
select="$funcsynopsis.tabular.threshold > 0
|
|
244
|
+
and string-length(.) > $funcsynopsis.tabular.threshold"/>
|
|
245
|
+
-->
|
|
246
|
+
|
|
247
|
+
<xsl:variable name="tabular-p" select="true()"/>
|
|
248
|
+
|
|
249
|
+
<xsl:choose>
|
|
250
|
+
<xsl:when test="$style = 'kr' and $tabular-p">
|
|
251
|
+
<xsl:apply-templates select="." mode="kr-tabular"/>
|
|
252
|
+
</xsl:when>
|
|
253
|
+
<xsl:when test="$style = 'kr'">
|
|
254
|
+
<xsl:apply-templates select="." mode="kr-nontabular"/>
|
|
255
|
+
</xsl:when>
|
|
256
|
+
<xsl:when test="$style = 'ansi' and $tabular-p">
|
|
257
|
+
<xsl:apply-templates select="." mode="ansi-tabular"/>
|
|
258
|
+
</xsl:when>
|
|
259
|
+
<xsl:otherwise>
|
|
260
|
+
<xsl:apply-templates select="." mode="ansi-nontabular"/>
|
|
261
|
+
</xsl:otherwise>
|
|
262
|
+
</xsl:choose>
|
|
263
|
+
</xsl:template>
|
|
264
|
+
|
|
265
|
+
<!-- ====================================================================== -->
|
|
266
|
+
<!-- funcprototype: kr, non-tabular -->
|
|
267
|
+
|
|
268
|
+
<xsl:template match="d:funcprototype" mode="kr-nontabular">
|
|
269
|
+
<p>
|
|
270
|
+
<xsl:apply-templates mode="kr-nontabular"/>
|
|
271
|
+
<xsl:if test="d:paramdef">
|
|
272
|
+
<br/>
|
|
273
|
+
<xsl:apply-templates select="d:paramdef" mode="kr-funcsynopsis-mode"/>
|
|
274
|
+
</xsl:if>
|
|
275
|
+
</p>
|
|
276
|
+
</xsl:template>
|
|
277
|
+
|
|
278
|
+
<xsl:template match="d:funcdef" mode="kr-nontabular">
|
|
279
|
+
<code>
|
|
280
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
281
|
+
<xsl:call-template name="id.attribute"/>
|
|
282
|
+
<xsl:apply-templates mode="kr-nontabular"/>
|
|
283
|
+
<xsl:text>(</xsl:text>
|
|
284
|
+
</code>
|
|
285
|
+
</xsl:template>
|
|
286
|
+
|
|
287
|
+
<xsl:template match="d:funcdef/d:function" mode="kr-nontabular">
|
|
288
|
+
<xsl:choose>
|
|
289
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
290
|
+
<strong xmlns:xslo="http://www.w3.org/1999/XSL/Transform" class="fsfunc"><xsl:apply-templates mode="kr-nontabular"/></strong>
|
|
291
|
+
</xsl:when>
|
|
292
|
+
<xsl:otherwise>
|
|
293
|
+
<xsl:apply-templates mode="kr-nontabular"/>
|
|
294
|
+
</xsl:otherwise>
|
|
295
|
+
</xsl:choose>
|
|
296
|
+
</xsl:template>
|
|
297
|
+
|
|
298
|
+
<xsl:template match="d:void" mode="kr-nontabular">
|
|
299
|
+
<code>)</code>
|
|
300
|
+
<xsl:text>;</xsl:text>
|
|
301
|
+
</xsl:template>
|
|
302
|
+
|
|
303
|
+
<xsl:template match="d:varargs" mode="kr-nontabular">
|
|
304
|
+
<xsl:text>...</xsl:text>
|
|
305
|
+
<code>)</code>
|
|
306
|
+
<xsl:text>;</xsl:text>
|
|
307
|
+
</xsl:template>
|
|
308
|
+
|
|
309
|
+
<xsl:template match="d:paramdef" mode="kr-nontabular">
|
|
310
|
+
<xsl:apply-templates select="d:parameter" mode="kr-nontabular"/>
|
|
311
|
+
<xsl:choose>
|
|
312
|
+
<xsl:when test="following-sibling::*">
|
|
313
|
+
<xsl:text>, </xsl:text>
|
|
314
|
+
</xsl:when>
|
|
315
|
+
<xsl:otherwise>
|
|
316
|
+
<code>)</code>
|
|
317
|
+
<xsl:text>;</xsl:text>
|
|
318
|
+
</xsl:otherwise>
|
|
319
|
+
</xsl:choose>
|
|
320
|
+
</xsl:template>
|
|
321
|
+
|
|
322
|
+
<xsl:template match="d:paramdef/d:parameter" mode="kr-nontabular">
|
|
323
|
+
<xsl:choose>
|
|
324
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
325
|
+
<var class="pdparam">
|
|
326
|
+
<xsl:apply-templates mode="kr-nontabular"/>
|
|
327
|
+
</var>
|
|
328
|
+
</xsl:when>
|
|
329
|
+
<xsl:otherwise>
|
|
330
|
+
<code>
|
|
331
|
+
<xsl:apply-templates mode="kr-nontabular"/>
|
|
332
|
+
</code>
|
|
333
|
+
</xsl:otherwise>
|
|
334
|
+
</xsl:choose>
|
|
335
|
+
</xsl:template>
|
|
336
|
+
|
|
337
|
+
<xsl:template match="d:paramdef" mode="kr-funcsynopsis-mode">
|
|
338
|
+
<xsl:if test="preceding-sibling::d:paramdef"><br/></xsl:if>
|
|
339
|
+
<code>
|
|
340
|
+
<xsl:apply-templates mode="kr-funcsynopsis-mode"/>
|
|
341
|
+
</code>
|
|
342
|
+
<xsl:text>;</xsl:text>
|
|
343
|
+
</xsl:template>
|
|
344
|
+
|
|
345
|
+
<xsl:template match="d:paramdef/d:parameter" mode="kr-funcsynopsis-mode">
|
|
346
|
+
<xsl:choose>
|
|
347
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
348
|
+
<var class="pdparam">
|
|
349
|
+
<xsl:apply-templates mode="kr-funcsynopsis-mode"/>
|
|
350
|
+
</var>
|
|
351
|
+
</xsl:when>
|
|
352
|
+
<xsl:otherwise>
|
|
353
|
+
<code>
|
|
354
|
+
<xsl:apply-templates mode="kr-funcsynopsis-mode"/>
|
|
355
|
+
</code>
|
|
356
|
+
</xsl:otherwise>
|
|
357
|
+
</xsl:choose>
|
|
358
|
+
</xsl:template>
|
|
359
|
+
|
|
360
|
+
<xsl:template match="d:funcparams" mode="kr-funcsynopsis-mode">
|
|
361
|
+
<code>(</code>
|
|
362
|
+
<xsl:apply-templates mode="kr-funcsynopsis-mode"/>
|
|
363
|
+
<code>)</code>
|
|
364
|
+
</xsl:template>
|
|
365
|
+
|
|
366
|
+
<!-- ====================================================================== -->
|
|
367
|
+
<!-- funcprototype: kr, tabular -->
|
|
368
|
+
|
|
369
|
+
<xsl:template match="d:funcprototype" mode="kr-tabular">
|
|
370
|
+
<table border="{$table.border.off}" class="funcprototype-table">
|
|
371
|
+
<xsl:if test="$div.element != 'section'">
|
|
372
|
+
<xsl:attribute name="summary">Function synopsis</xsl:attribute>
|
|
373
|
+
</xsl:if>
|
|
374
|
+
<xsl:if test="$css.decoration != 0">
|
|
375
|
+
<xsl:attribute name="style">cellspacing: 0; cellpadding: 0;</xsl:attribute>
|
|
376
|
+
</xsl:if>
|
|
377
|
+
<tr>
|
|
378
|
+
<td>
|
|
379
|
+
<xsl:apply-templates select="d:funcdef" mode="kr-tabular"/>
|
|
380
|
+
</td>
|
|
381
|
+
<xsl:apply-templates select="(d:void|d:varargs|d:paramdef)[1]" mode="kr-tabular"/>
|
|
382
|
+
</tr>
|
|
383
|
+
<xsl:for-each select="(d:void|d:varargs|d:paramdef)[preceding-sibling::*[not(self::d:funcdef)]]">
|
|
384
|
+
<tr>
|
|
385
|
+
<td> </td>
|
|
386
|
+
<xsl:apply-templates select="." mode="kr-tabular"/>
|
|
387
|
+
</tr>
|
|
388
|
+
</xsl:for-each>
|
|
389
|
+
</table>
|
|
390
|
+
<xsl:if test="d:paramdef">
|
|
391
|
+
<div class="paramdef-list">
|
|
392
|
+
<xsl:apply-templates select="d:paramdef" mode="kr-funcsynopsis-mode"/>
|
|
393
|
+
</div>
|
|
394
|
+
</xsl:if>
|
|
395
|
+
<div class="funcprototype-spacer"> </div> <!-- hACk: blank div for vertical spacing -->
|
|
396
|
+
</xsl:template>
|
|
397
|
+
|
|
398
|
+
<xsl:template match="d:funcdef" mode="kr-tabular">
|
|
399
|
+
<code>
|
|
400
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
401
|
+
<xsl:call-template name="id.attribute"/>
|
|
402
|
+
<xsl:apply-templates mode="kr-tabular"/>
|
|
403
|
+
<xsl:text>(</xsl:text>
|
|
404
|
+
</code>
|
|
405
|
+
</xsl:template>
|
|
406
|
+
|
|
407
|
+
<xsl:template match="d:funcdef/d:function" mode="kr-tabular">
|
|
408
|
+
<xsl:choose>
|
|
409
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
410
|
+
<strong xmlns:xslo="http://www.w3.org/1999/XSL/Transform" class="fsfunc"><xsl:apply-templates mode="kr-nontabular"/></strong>
|
|
411
|
+
</xsl:when>
|
|
412
|
+
<xsl:otherwise>
|
|
413
|
+
<xsl:apply-templates mode="kr-tabular"/>
|
|
414
|
+
</xsl:otherwise>
|
|
415
|
+
</xsl:choose>
|
|
416
|
+
</xsl:template>
|
|
417
|
+
|
|
418
|
+
<xsl:template match="d:void" mode="kr-tabular">
|
|
419
|
+
<td>
|
|
420
|
+
<code>)</code>
|
|
421
|
+
<xsl:text>;</xsl:text>
|
|
422
|
+
</td>
|
|
423
|
+
<td> </td>
|
|
424
|
+
</xsl:template>
|
|
425
|
+
|
|
426
|
+
<xsl:template match="d:varargs" mode="kr-tabular">
|
|
427
|
+
<td>
|
|
428
|
+
<xsl:text>...</xsl:text>
|
|
429
|
+
<code>)</code>
|
|
430
|
+
<xsl:text>;</xsl:text>
|
|
431
|
+
</td>
|
|
432
|
+
<td> </td>
|
|
433
|
+
</xsl:template>
|
|
434
|
+
|
|
435
|
+
<xsl:template match="d:paramdef" mode="kr-tabular">
|
|
436
|
+
<td>
|
|
437
|
+
<xsl:apply-templates select="d:parameter" mode="kr-tabular"/>
|
|
438
|
+
<xsl:choose>
|
|
439
|
+
<xsl:when test="following-sibling::*">
|
|
440
|
+
<xsl:text>, </xsl:text>
|
|
441
|
+
</xsl:when>
|
|
442
|
+
<xsl:otherwise>
|
|
443
|
+
<code>)</code>
|
|
444
|
+
<xsl:text>;</xsl:text>
|
|
445
|
+
</xsl:otherwise>
|
|
446
|
+
</xsl:choose>
|
|
447
|
+
</td>
|
|
448
|
+
<td> </td>
|
|
449
|
+
</xsl:template>
|
|
450
|
+
|
|
451
|
+
<xsl:template match="d:paramdef/d:parameter" mode="kr-tabular">
|
|
452
|
+
<xsl:choose>
|
|
453
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
454
|
+
<var class="pdparam">
|
|
455
|
+
<xsl:apply-templates mode="kr-tabular"/>
|
|
456
|
+
</var>
|
|
457
|
+
</xsl:when>
|
|
458
|
+
<xsl:otherwise>
|
|
459
|
+
<code>
|
|
460
|
+
<xsl:apply-templates mode="kr-tabular"/>
|
|
461
|
+
</code>
|
|
462
|
+
</xsl:otherwise>
|
|
463
|
+
</xsl:choose>
|
|
464
|
+
</xsl:template>
|
|
465
|
+
|
|
466
|
+
<xsl:template match="d:paramdef" mode="kr-tabular-funcsynopsis-mode">
|
|
467
|
+
<xsl:variable name="type">
|
|
468
|
+
<xsl:choose>
|
|
469
|
+
<xsl:when test="d:type">
|
|
470
|
+
<xsl:apply-templates select="d:type" mode="kr-tabular-funcsynopsis-mode"/>
|
|
471
|
+
</xsl:when>
|
|
472
|
+
<xsl:when test="normalize-space(d:parameter/preceding-sibling::node()[not(self::d:parameter)]) != ''">
|
|
473
|
+
<xsl:copy-of select="d:parameter/preceding-sibling::node()[not(self::d:parameter)]"/>
|
|
474
|
+
</xsl:when>
|
|
475
|
+
</xsl:choose>
|
|
476
|
+
</xsl:variable>
|
|
477
|
+
|
|
478
|
+
<tr>
|
|
479
|
+
<xsl:choose>
|
|
480
|
+
<xsl:when test="$type != '' and d:funcparams">
|
|
481
|
+
<td>
|
|
482
|
+
<code>
|
|
483
|
+
<xsl:copy-of select="$type"/>
|
|
484
|
+
</code>
|
|
485
|
+
<xsl:text> </xsl:text>
|
|
486
|
+
</td>
|
|
487
|
+
<td>
|
|
488
|
+
<code>
|
|
489
|
+
<xsl:choose>
|
|
490
|
+
<xsl:when test="d:type">
|
|
491
|
+
<xsl:apply-templates select="d:type/following-sibling::*" mode="kr-tabular-funcsynopsis-mode"/>
|
|
492
|
+
</xsl:when>
|
|
493
|
+
<xsl:otherwise>
|
|
494
|
+
<xsl:apply-templates select="*" mode="kr-tabular-funcsynopsis-mode"/>
|
|
495
|
+
</xsl:otherwise>
|
|
496
|
+
</xsl:choose>
|
|
497
|
+
</code>
|
|
498
|
+
</td>
|
|
499
|
+
</xsl:when>
|
|
500
|
+
|
|
501
|
+
<xsl:when test="d:funcparams">
|
|
502
|
+
<td colspan="2">
|
|
503
|
+
<code>
|
|
504
|
+
<xsl:apply-templates mode="kr-tabular-funcsynopsis-mode"/>
|
|
505
|
+
</code>
|
|
506
|
+
</td>
|
|
507
|
+
</xsl:when>
|
|
508
|
+
|
|
509
|
+
<xsl:otherwise>
|
|
510
|
+
<td>
|
|
511
|
+
<code>
|
|
512
|
+
<xsl:apply-templates select="d:parameter/preceding-sibling::node()[not(self::d:parameter)]" mode="kr-tabular-funcsynopsis-mode"/>
|
|
513
|
+
</code>
|
|
514
|
+
<xsl:text> </xsl:text>
|
|
515
|
+
</td>
|
|
516
|
+
<td>
|
|
517
|
+
<code>
|
|
518
|
+
<xsl:apply-templates select="d:parameter" mode="kr-tabular"/>
|
|
519
|
+
<xsl:apply-templates select="d:parameter/following-sibling::*[not(self::d:parameter)]" mode="kr-tabular-funcsynopsis-mode"/>
|
|
520
|
+
<xsl:text>;</xsl:text>
|
|
521
|
+
</code>
|
|
522
|
+
</td>
|
|
523
|
+
</xsl:otherwise>
|
|
524
|
+
</xsl:choose>
|
|
525
|
+
</tr>
|
|
526
|
+
</xsl:template>
|
|
527
|
+
|
|
528
|
+
<xsl:template match="d:paramdef/d:parameter" mode="kr-tabular-funcsynopsis-mode">
|
|
529
|
+
<xsl:choose>
|
|
530
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
531
|
+
<var class="pdparam">
|
|
532
|
+
<xsl:apply-templates mode="kr-tabular-funcsynopsis-mode"/>
|
|
533
|
+
</var>
|
|
534
|
+
</xsl:when>
|
|
535
|
+
<xsl:otherwise>
|
|
536
|
+
<code>
|
|
537
|
+
<xsl:apply-templates mode="kr-tabular-funcsynopsis-mode"/>
|
|
538
|
+
</code>
|
|
539
|
+
</xsl:otherwise>
|
|
540
|
+
</xsl:choose>
|
|
541
|
+
</xsl:template>
|
|
542
|
+
|
|
543
|
+
<xsl:template match="d:funcparams" mode="kr-tabular-funcsynopsis-mode">
|
|
544
|
+
<code>(</code>
|
|
545
|
+
<xsl:apply-templates mode="kr-tabular-funcsynopsis-mode"/>
|
|
546
|
+
<code>)</code>
|
|
547
|
+
<xsl:text>;</xsl:text>
|
|
548
|
+
</xsl:template>
|
|
549
|
+
|
|
550
|
+
<!-- ====================================================================== -->
|
|
551
|
+
<!-- funcprototype: ansi, non-tabular -->
|
|
552
|
+
|
|
553
|
+
<xsl:template match="d:funcprototype" mode="ansi-nontabular">
|
|
554
|
+
<p>
|
|
555
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
556
|
+
</p>
|
|
557
|
+
</xsl:template>
|
|
558
|
+
|
|
559
|
+
<xsl:template match="d:funcdef" mode="ansi-nontabular">
|
|
560
|
+
<code>
|
|
561
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
562
|
+
<xsl:call-template name="id.attribute"/>
|
|
563
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
564
|
+
<xsl:text>(</xsl:text>
|
|
565
|
+
</code>
|
|
566
|
+
</xsl:template>
|
|
567
|
+
|
|
568
|
+
<xsl:template match="d:funcdef/d:function" mode="ansi-nontabular">
|
|
569
|
+
<xsl:choose>
|
|
570
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
571
|
+
<strong xmlns:xslo="http://www.w3.org/1999/XSL/Transform" class="fsfunc"><xsl:apply-templates mode="ansi-nontabular"/></strong>
|
|
572
|
+
</xsl:when>
|
|
573
|
+
<xsl:otherwise>
|
|
574
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
575
|
+
</xsl:otherwise>
|
|
576
|
+
</xsl:choose>
|
|
577
|
+
</xsl:template>
|
|
578
|
+
|
|
579
|
+
<xsl:template match="d:void" mode="ansi-nontabular">
|
|
580
|
+
<code>void)</code>
|
|
581
|
+
<xsl:text>;</xsl:text>
|
|
582
|
+
</xsl:template>
|
|
583
|
+
|
|
584
|
+
<xsl:template match="d:varargs" mode="ansi-nontabular">
|
|
585
|
+
<xsl:text>...</xsl:text>
|
|
586
|
+
<code>)</code>
|
|
587
|
+
<xsl:text>;</xsl:text>
|
|
588
|
+
</xsl:template>
|
|
589
|
+
|
|
590
|
+
<xsl:template match="d:paramdef" mode="ansi-nontabular">
|
|
591
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
592
|
+
<xsl:choose>
|
|
593
|
+
<xsl:when test="following-sibling::*">
|
|
594
|
+
<xsl:text>, </xsl:text>
|
|
595
|
+
</xsl:when>
|
|
596
|
+
<xsl:otherwise>
|
|
597
|
+
<code>)</code>
|
|
598
|
+
<xsl:text>;</xsl:text>
|
|
599
|
+
</xsl:otherwise>
|
|
600
|
+
</xsl:choose>
|
|
601
|
+
</xsl:template>
|
|
602
|
+
|
|
603
|
+
<xsl:template match="d:paramdef/d:parameter" mode="ansi-nontabular">
|
|
604
|
+
<xsl:choose>
|
|
605
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
606
|
+
<var class="pdparam">
|
|
607
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
608
|
+
</var>
|
|
609
|
+
</xsl:when>
|
|
610
|
+
<xsl:otherwise>
|
|
611
|
+
<code>
|
|
612
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
613
|
+
</code>
|
|
614
|
+
</xsl:otherwise>
|
|
615
|
+
</xsl:choose>
|
|
616
|
+
</xsl:template>
|
|
617
|
+
|
|
618
|
+
<xsl:template match="d:funcparams" mode="ansi-nontabular">
|
|
619
|
+
<code>(</code>
|
|
620
|
+
<xsl:apply-templates mode="ansi-nontabular"/>
|
|
621
|
+
<code>)</code>
|
|
622
|
+
</xsl:template>
|
|
623
|
+
|
|
624
|
+
<!-- ====================================================================== -->
|
|
625
|
+
<!-- funcprototype: ansi, tabular -->
|
|
626
|
+
|
|
627
|
+
<xsl:template match="d:funcprototype" mode="ansi-tabular">
|
|
628
|
+
<table border="{$table.border.off}" class="funcprototype-table">
|
|
629
|
+
<xsl:if test="$div.element != 'section'">
|
|
630
|
+
<xsl:attribute name="summary">Function synopsis</xsl:attribute>
|
|
631
|
+
</xsl:if>
|
|
632
|
+
<xsl:if test="$css.decoration != 0">
|
|
633
|
+
<xsl:attribute name="style">cellspacing: 0; cellpadding: 0;</xsl:attribute>
|
|
634
|
+
</xsl:if>
|
|
635
|
+
<tr>
|
|
636
|
+
<td>
|
|
637
|
+
<xsl:apply-templates select="d:funcdef" mode="ansi-tabular"/>
|
|
638
|
+
</td>
|
|
639
|
+
<xsl:apply-templates select="(d:void|d:varargs|d:paramdef)[1]" mode="ansi-tabular"/>
|
|
640
|
+
</tr>
|
|
641
|
+
<xsl:for-each select="(d:void|d:varargs|d:paramdef)[preceding-sibling::*[not(self::d:funcdef)]]">
|
|
642
|
+
<tr>
|
|
643
|
+
<td> </td>
|
|
644
|
+
<xsl:apply-templates select="." mode="ansi-tabular"/>
|
|
645
|
+
</tr>
|
|
646
|
+
</xsl:for-each>
|
|
647
|
+
</table>
|
|
648
|
+
<div class="funcprototype-spacer"> </div> <!-- hACk: blank div for vertical spacing -->
|
|
649
|
+
</xsl:template>
|
|
650
|
+
|
|
651
|
+
<xsl:template match="d:funcdef" mode="ansi-tabular">
|
|
652
|
+
<code>
|
|
653
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
654
|
+
<xsl:call-template name="id.attribute"/>
|
|
655
|
+
<xsl:apply-templates mode="ansi-tabular"/>
|
|
656
|
+
<xsl:text>(</xsl:text>
|
|
657
|
+
</code>
|
|
658
|
+
</xsl:template>
|
|
659
|
+
|
|
660
|
+
<xsl:template match="d:funcdef/d:function" mode="ansi-tabular">
|
|
661
|
+
<xsl:choose>
|
|
662
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
663
|
+
<strong xmlns:xslo="http://www.w3.org/1999/XSL/Transform" class="fsfunc"><xsl:apply-templates mode="ansi-nontabular"/></strong>
|
|
664
|
+
</xsl:when>
|
|
665
|
+
<xsl:otherwise>
|
|
666
|
+
<xsl:apply-templates mode="kr-tabular"/>
|
|
667
|
+
</xsl:otherwise>
|
|
668
|
+
</xsl:choose>
|
|
669
|
+
</xsl:template>
|
|
670
|
+
|
|
671
|
+
<xsl:template match="d:void" mode="ansi-tabular">
|
|
672
|
+
<td>
|
|
673
|
+
<code>void)</code>
|
|
674
|
+
<xsl:text>;</xsl:text>
|
|
675
|
+
</td>
|
|
676
|
+
<td> </td>
|
|
677
|
+
</xsl:template>
|
|
678
|
+
|
|
679
|
+
<xsl:template match="d:varargs" mode="ansi-tabular">
|
|
680
|
+
<td>
|
|
681
|
+
<xsl:text>...</xsl:text>
|
|
682
|
+
<code>)</code>
|
|
683
|
+
<xsl:text>;</xsl:text>
|
|
684
|
+
</td>
|
|
685
|
+
<td> </td>
|
|
686
|
+
</xsl:template>
|
|
687
|
+
|
|
688
|
+
<xsl:template match="d:paramdef" mode="ansi-tabular">
|
|
689
|
+
<td>
|
|
690
|
+
<xsl:apply-templates mode="ansi-tabular"/>
|
|
691
|
+
<xsl:choose>
|
|
692
|
+
<xsl:when test="following-sibling::*">
|
|
693
|
+
<xsl:text>, </xsl:text>
|
|
694
|
+
</xsl:when>
|
|
695
|
+
<xsl:otherwise>
|
|
696
|
+
<code>)</code>
|
|
697
|
+
<xsl:text>;</xsl:text>
|
|
698
|
+
</xsl:otherwise>
|
|
699
|
+
</xsl:choose>
|
|
700
|
+
</td>
|
|
701
|
+
</xsl:template>
|
|
702
|
+
|
|
703
|
+
<xsl:template match="d:paramdef/d:parameter" mode="ansi-tabular">
|
|
704
|
+
<xsl:choose>
|
|
705
|
+
<xsl:when test="$funcsynopsis.decoration != 0">
|
|
706
|
+
<var class="pdparam">
|
|
707
|
+
<xsl:apply-templates mode="ansi-tabular"/>
|
|
708
|
+
</var>
|
|
709
|
+
</xsl:when>
|
|
710
|
+
<xsl:otherwise>
|
|
711
|
+
<code>
|
|
712
|
+
<xsl:apply-templates mode="ansi-tabular"/>
|
|
713
|
+
</code>
|
|
714
|
+
</xsl:otherwise>
|
|
715
|
+
</xsl:choose>
|
|
716
|
+
</xsl:template>
|
|
717
|
+
|
|
718
|
+
<xsl:template match="d:funcparams" mode="ansi-tabular">
|
|
719
|
+
<code>(</code>
|
|
720
|
+
<xsl:apply-templates/>
|
|
721
|
+
<code>)</code>
|
|
722
|
+
</xsl:template>
|
|
723
|
+
|
|
724
|
+
<!-- ====================================================================== -->
|
|
725
|
+
|
|
726
|
+
<xsl:variable name="default-classsynopsis-language">java</xsl:variable>
|
|
727
|
+
|
|
728
|
+
<xsl:template match="d:classsynopsis |d:fieldsynopsis |d:methodsynopsis |d:constructorsynopsis |d:destructorsynopsis">
|
|
729
|
+
<xsl:param name="language">
|
|
730
|
+
<xsl:choose>
|
|
731
|
+
<xsl:when test="@language">
|
|
732
|
+
<xsl:value-of select="@language"/>
|
|
733
|
+
</xsl:when>
|
|
734
|
+
<xsl:otherwise>
|
|
735
|
+
<xsl:value-of select="$default-classsynopsis-language"/>
|
|
736
|
+
</xsl:otherwise>
|
|
737
|
+
</xsl:choose>
|
|
738
|
+
</xsl:param>
|
|
739
|
+
|
|
740
|
+
<xsl:choose>
|
|
741
|
+
<xsl:when test="$language='java' or $language='Java'">
|
|
742
|
+
<xsl:apply-templates select="." mode="java"/>
|
|
743
|
+
</xsl:when>
|
|
744
|
+
<xsl:when test="$language='perl' or $language='Perl'">
|
|
745
|
+
<xsl:apply-templates select="." mode="perl"/>
|
|
746
|
+
</xsl:when>
|
|
747
|
+
<xsl:when test="$language='idl' or $language='IDL'">
|
|
748
|
+
<xsl:apply-templates select="." mode="idl"/>
|
|
749
|
+
</xsl:when>
|
|
750
|
+
<xsl:when test="$language='cpp' or $language='c++' or $language='C++'">
|
|
751
|
+
<xsl:apply-templates select="." mode="cpp"/>
|
|
752
|
+
</xsl:when>
|
|
753
|
+
<xsl:otherwise>
|
|
754
|
+
<xsl:message>
|
|
755
|
+
<xsl:text>Unrecognized language on </xsl:text>
|
|
756
|
+
<xsl:value-of select="local-name(.)"/>
|
|
757
|
+
<xsl:text>: </xsl:text>
|
|
758
|
+
<xsl:value-of select="$language"/>
|
|
759
|
+
</xsl:message>
|
|
760
|
+
<xsl:apply-templates select=".">
|
|
761
|
+
<xsl:with-param name="language" select="$default-classsynopsis-language"/>
|
|
762
|
+
</xsl:apply-templates>
|
|
763
|
+
</xsl:otherwise>
|
|
764
|
+
</xsl:choose>
|
|
765
|
+
</xsl:template>
|
|
766
|
+
|
|
767
|
+
<xsl:template name="synop-break">
|
|
768
|
+
<xsl:if test="parent::d:classsynopsis or (following-sibling::d:fieldsynopsis |following-sibling::d:methodsynopsis |following-sibling::d:constructorsynopsis |following-sibling::d:destructorsynopsis)">
|
|
769
|
+
<br/>
|
|
770
|
+
</xsl:if>
|
|
771
|
+
</xsl:template>
|
|
772
|
+
|
|
773
|
+
|
|
774
|
+
<!-- ===== Java ======================================================== -->
|
|
775
|
+
|
|
776
|
+
<xsl:template match="d:classsynopsis" mode="java">
|
|
777
|
+
<pre>
|
|
778
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
779
|
+
<xsl:call-template name="id.attribute"/>
|
|
780
|
+
<xsl:apply-templates select="d:ooclass[1]" mode="java"/>
|
|
781
|
+
<xsl:if test="d:ooclass[preceding-sibling::*]">
|
|
782
|
+
<xsl:text> extends</xsl:text>
|
|
783
|
+
<xsl:apply-templates select="d:ooclass[preceding-sibling::*]" mode="java"/>
|
|
784
|
+
<xsl:if test="d:oointerface|d:ooexception">
|
|
785
|
+
<br/>
|
|
786
|
+
<xsl:text>    </xsl:text>
|
|
787
|
+
</xsl:if>
|
|
788
|
+
</xsl:if>
|
|
789
|
+
<xsl:if test="d:oointerface">
|
|
790
|
+
<xsl:text>implements</xsl:text>
|
|
791
|
+
<xsl:apply-templates select="d:oointerface" mode="java"/>
|
|
792
|
+
<xsl:if test="d:ooexception">
|
|
793
|
+
<br/>
|
|
794
|
+
<xsl:text>    </xsl:text>
|
|
795
|
+
</xsl:if>
|
|
796
|
+
</xsl:if>
|
|
797
|
+
<xsl:if test="d:ooexception">
|
|
798
|
+
<xsl:text>throws</xsl:text>
|
|
799
|
+
<xsl:apply-templates select="d:ooexception" mode="java"/>
|
|
800
|
+
</xsl:if>
|
|
801
|
+
<xsl:text> {</xsl:text>
|
|
802
|
+
<br/>
|
|
803
|
+
<xsl:apply-templates select="d:constructorsynopsis |d:destructorsynopsis |d:fieldsynopsis |d:methodsynopsis |d:classsynopsisinfo" mode="java"/>
|
|
804
|
+
<xsl:text>}</xsl:text>
|
|
805
|
+
</pre>
|
|
806
|
+
</xsl:template>
|
|
807
|
+
|
|
808
|
+
<xsl:template match="d:classsynopsisinfo" mode="java">
|
|
809
|
+
<xsl:apply-templates mode="java"/>
|
|
810
|
+
</xsl:template>
|
|
811
|
+
|
|
812
|
+
<xsl:template match="d:ooclass|d:oointerface|d:ooexception" mode="java">
|
|
813
|
+
<xsl:choose>
|
|
814
|
+
<xsl:when test="preceding-sibling::*">
|
|
815
|
+
<xsl:text>, </xsl:text>
|
|
816
|
+
</xsl:when>
|
|
817
|
+
<xsl:otherwise>
|
|
818
|
+
<xsl:text> </xsl:text>
|
|
819
|
+
</xsl:otherwise>
|
|
820
|
+
</xsl:choose>
|
|
821
|
+
<span>
|
|
822
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
823
|
+
<xsl:call-template name="id.attribute"/>
|
|
824
|
+
<xsl:apply-templates mode="java"/>
|
|
825
|
+
</span>
|
|
826
|
+
</xsl:template>
|
|
827
|
+
|
|
828
|
+
<xsl:template match="d:modifier|d:package" mode="java">
|
|
829
|
+
<span>
|
|
830
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
831
|
+
<xsl:call-template name="id.attribute"/>
|
|
832
|
+
<xsl:apply-templates mode="java"/>
|
|
833
|
+
<xsl:if test="following-sibling::*">
|
|
834
|
+
<xsl:text> </xsl:text>
|
|
835
|
+
</xsl:if>
|
|
836
|
+
</span>
|
|
837
|
+
</xsl:template>
|
|
838
|
+
|
|
839
|
+
<xsl:template match="d:classname" mode="java">
|
|
840
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'classname'">
|
|
841
|
+
<xsl:text>, </xsl:text>
|
|
842
|
+
</xsl:if>
|
|
843
|
+
<span>
|
|
844
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
845
|
+
<xsl:call-template name="id.attribute"/>
|
|
846
|
+
<xsl:apply-templates mode="java"/>
|
|
847
|
+
</span>
|
|
848
|
+
</xsl:template>
|
|
849
|
+
|
|
850
|
+
<xsl:template match="d:interfacename" mode="java">
|
|
851
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'interfacename'">
|
|
852
|
+
<xsl:text>, </xsl:text>
|
|
853
|
+
</xsl:if>
|
|
854
|
+
<span>
|
|
855
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
856
|
+
<xsl:call-template name="id.attribute"/>
|
|
857
|
+
<xsl:apply-templates mode="java"/>
|
|
858
|
+
</span>
|
|
859
|
+
</xsl:template>
|
|
860
|
+
|
|
861
|
+
<xsl:template match="d:exceptionname" mode="java">
|
|
862
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'exceptionname'">
|
|
863
|
+
<xsl:text>, </xsl:text>
|
|
864
|
+
</xsl:if>
|
|
865
|
+
<span>
|
|
866
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
867
|
+
<xsl:call-template name="id.attribute"/>
|
|
868
|
+
<xsl:apply-templates mode="java"/>
|
|
869
|
+
</span>
|
|
870
|
+
</xsl:template>
|
|
871
|
+
|
|
872
|
+
<xsl:template match="d:fieldsynopsis" mode="java">
|
|
873
|
+
<code>
|
|
874
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
875
|
+
<xsl:call-template name="id.attribute"/>
|
|
876
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
877
|
+
<xsl:text>  </xsl:text>
|
|
878
|
+
</xsl:if>
|
|
879
|
+
<xsl:apply-templates mode="java"/>
|
|
880
|
+
<xsl:text>;</xsl:text>
|
|
881
|
+
</code>
|
|
882
|
+
<xsl:call-template name="synop-break"/>
|
|
883
|
+
</xsl:template>
|
|
884
|
+
|
|
885
|
+
<xsl:template match="d:type" mode="java">
|
|
886
|
+
<span>
|
|
887
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
888
|
+
<xsl:call-template name="id.attribute"/>
|
|
889
|
+
<xsl:apply-templates mode="java"/>
|
|
890
|
+
<xsl:text> </xsl:text>
|
|
891
|
+
</span>
|
|
892
|
+
</xsl:template>
|
|
893
|
+
|
|
894
|
+
<xsl:template match="d:varname" mode="java">
|
|
895
|
+
<span>
|
|
896
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
897
|
+
<xsl:call-template name="id.attribute"/>
|
|
898
|
+
<xsl:apply-templates mode="java"/>
|
|
899
|
+
<xsl:text> </xsl:text>
|
|
900
|
+
</span>
|
|
901
|
+
</xsl:template>
|
|
902
|
+
|
|
903
|
+
<xsl:template match="d:initializer" mode="java">
|
|
904
|
+
<span>
|
|
905
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
906
|
+
<xsl:call-template name="id.attribute"/>
|
|
907
|
+
<xsl:text>= </xsl:text>
|
|
908
|
+
<xsl:apply-templates mode="java"/>
|
|
909
|
+
</span>
|
|
910
|
+
</xsl:template>
|
|
911
|
+
|
|
912
|
+
<xsl:template match="d:void" mode="java">
|
|
913
|
+
<span>
|
|
914
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
915
|
+
<xsl:call-template name="id.attribute"/>
|
|
916
|
+
<xsl:text>void </xsl:text>
|
|
917
|
+
</span>
|
|
918
|
+
</xsl:template>
|
|
919
|
+
|
|
920
|
+
<xsl:template match="d:methodname" mode="java">
|
|
921
|
+
<span>
|
|
922
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
923
|
+
<xsl:call-template name="id.attribute"/>
|
|
924
|
+
<xsl:apply-templates mode="java"/>
|
|
925
|
+
</span>
|
|
926
|
+
</xsl:template>
|
|
927
|
+
|
|
928
|
+
<xsl:template match="d:methodparam" mode="java">
|
|
929
|
+
<xsl:param name="indent">0</xsl:param>
|
|
930
|
+
<xsl:if test="preceding-sibling::d:methodparam">
|
|
931
|
+
<xsl:text>,</xsl:text>
|
|
932
|
+
<br/>
|
|
933
|
+
<xsl:if test="$indent > 0">
|
|
934
|
+
<xsl:call-template name="copy-string">
|
|
935
|
+
<xsl:with-param name="string"> </xsl:with-param>
|
|
936
|
+
<xsl:with-param name="count" select="$indent + 1"/>
|
|
937
|
+
</xsl:call-template>
|
|
938
|
+
</xsl:if>
|
|
939
|
+
</xsl:if>
|
|
940
|
+
<span>
|
|
941
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
942
|
+
<xsl:call-template name="id.attribute"/>
|
|
943
|
+
<xsl:apply-templates mode="java"/>
|
|
944
|
+
</span>
|
|
945
|
+
</xsl:template>
|
|
946
|
+
|
|
947
|
+
<xsl:template match="d:parameter" mode="java">
|
|
948
|
+
<span>
|
|
949
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
950
|
+
<xsl:call-template name="id.attribute"/>
|
|
951
|
+
<xsl:apply-templates mode="java"/>
|
|
952
|
+
</span>
|
|
953
|
+
</xsl:template>
|
|
954
|
+
|
|
955
|
+
<xsl:template mode="java" match="d:constructorsynopsis|d:destructorsynopsis|d:methodsynopsis">
|
|
956
|
+
<xsl:variable name="start-modifiers" select="d:modifier[following-sibling::*[local-name(.) != 'modifier']]"/>
|
|
957
|
+
<xsl:variable name="notmod" select="*[local-name(.) != 'modifier']"/>
|
|
958
|
+
<xsl:variable name="end-modifiers" select="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]"/>
|
|
959
|
+
<xsl:variable name="decl">
|
|
960
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
961
|
+
<xsl:text>  </xsl:text>
|
|
962
|
+
</xsl:if>
|
|
963
|
+
<xsl:apply-templates select="$start-modifiers" mode="java"/>
|
|
964
|
+
|
|
965
|
+
<!-- type -->
|
|
966
|
+
<xsl:if test="local-name($notmod[1]) != 'methodname'">
|
|
967
|
+
<xsl:apply-templates select="$notmod[1]" mode="java"/>
|
|
968
|
+
</xsl:if>
|
|
969
|
+
|
|
970
|
+
<xsl:apply-templates select="d:methodname" mode="java"/>
|
|
971
|
+
</xsl:variable>
|
|
972
|
+
|
|
973
|
+
<code>
|
|
974
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
975
|
+
<xsl:call-template name="id.attribute"/>
|
|
976
|
+
<xsl:copy-of select="$decl"/>
|
|
977
|
+
<xsl:text>(</xsl:text>
|
|
978
|
+
<xsl:apply-templates select="d:methodparam" mode="java">
|
|
979
|
+
<xsl:with-param name="indent" select="string-length($decl)"/>
|
|
980
|
+
</xsl:apply-templates>
|
|
981
|
+
<xsl:text>)</xsl:text>
|
|
982
|
+
<xsl:if test="d:exceptionname">
|
|
983
|
+
<br/>
|
|
984
|
+
<xsl:text>    throws </xsl:text>
|
|
985
|
+
<xsl:apply-templates select="d:exceptionname" mode="java"/>
|
|
986
|
+
</xsl:if>
|
|
987
|
+
<xsl:if test="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]">
|
|
988
|
+
<xsl:text> </xsl:text>
|
|
989
|
+
<xsl:apply-templates select="$end-modifiers" mode="java"/>
|
|
990
|
+
</xsl:if>
|
|
991
|
+
<xsl:text>;</xsl:text>
|
|
992
|
+
</code>
|
|
993
|
+
<xsl:call-template name="synop-break"/>
|
|
994
|
+
</xsl:template>
|
|
995
|
+
|
|
996
|
+
<!-- ===== C++ ========================================================= -->
|
|
997
|
+
|
|
998
|
+
<xsl:template match="d:classsynopsis" mode="cpp">
|
|
999
|
+
<pre>
|
|
1000
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1001
|
+
<xsl:call-template name="id.attribute"/>
|
|
1002
|
+
<xsl:apply-templates select="d:ooclass[1]" mode="cpp"/>
|
|
1003
|
+
<xsl:if test="d:ooclass[preceding-sibling::*]">
|
|
1004
|
+
<xsl:text>: </xsl:text>
|
|
1005
|
+
<xsl:apply-templates select="d:ooclass[preceding-sibling::*]" mode="cpp"/>
|
|
1006
|
+
<xsl:if test="d:oointerface|d:ooexception">
|
|
1007
|
+
<br/>
|
|
1008
|
+
<xsl:text>    </xsl:text>
|
|
1009
|
+
</xsl:if>
|
|
1010
|
+
</xsl:if>
|
|
1011
|
+
<xsl:if test="d:oointerface">
|
|
1012
|
+
<xsl:text> implements</xsl:text>
|
|
1013
|
+
<xsl:apply-templates select="d:oointerface" mode="cpp"/>
|
|
1014
|
+
<xsl:if test="d:ooexception">
|
|
1015
|
+
<br/>
|
|
1016
|
+
<xsl:text>    </xsl:text>
|
|
1017
|
+
</xsl:if>
|
|
1018
|
+
</xsl:if>
|
|
1019
|
+
<xsl:if test="d:ooexception">
|
|
1020
|
+
<xsl:text> throws</xsl:text>
|
|
1021
|
+
<xsl:apply-templates select="d:ooexception" mode="cpp"/>
|
|
1022
|
+
</xsl:if>
|
|
1023
|
+
<xsl:text> {</xsl:text>
|
|
1024
|
+
<br/>
|
|
1025
|
+
<xsl:apply-templates select="d:constructorsynopsis |d:destructorsynopsis |d:fieldsynopsis |d:methodsynopsis |d:classsynopsisinfo" mode="cpp"/>
|
|
1026
|
+
<xsl:text>}</xsl:text>
|
|
1027
|
+
</pre>
|
|
1028
|
+
</xsl:template>
|
|
1029
|
+
|
|
1030
|
+
<xsl:template match="d:classsynopsisinfo" mode="cpp">
|
|
1031
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1032
|
+
</xsl:template>
|
|
1033
|
+
|
|
1034
|
+
<xsl:template match="d:ooclass|d:oointerface|d:ooexception" mode="cpp">
|
|
1035
|
+
<xsl:if test="preceding-sibling::*">
|
|
1036
|
+
<xsl:text>, </xsl:text>
|
|
1037
|
+
</xsl:if>
|
|
1038
|
+
<span>
|
|
1039
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1040
|
+
<xsl:call-template name="id.attribute"/>
|
|
1041
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1042
|
+
</span>
|
|
1043
|
+
</xsl:template>
|
|
1044
|
+
|
|
1045
|
+
<xsl:template match="d:modifier|d:package" mode="cpp">
|
|
1046
|
+
<span>
|
|
1047
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1048
|
+
<xsl:call-template name="id.attribute"/>
|
|
1049
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1050
|
+
<xsl:if test="following-sibling::*">
|
|
1051
|
+
<xsl:text> </xsl:text>
|
|
1052
|
+
</xsl:if>
|
|
1053
|
+
</span>
|
|
1054
|
+
</xsl:template>
|
|
1055
|
+
|
|
1056
|
+
<xsl:template match="d:classname" mode="cpp">
|
|
1057
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'classname'">
|
|
1058
|
+
<xsl:text>, </xsl:text>
|
|
1059
|
+
</xsl:if>
|
|
1060
|
+
<span>
|
|
1061
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1062
|
+
<xsl:call-template name="id.attribute"/>
|
|
1063
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1064
|
+
</span>
|
|
1065
|
+
</xsl:template>
|
|
1066
|
+
|
|
1067
|
+
<xsl:template match="d:interfacename" mode="cpp">
|
|
1068
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'interfacename'">
|
|
1069
|
+
<xsl:text>, </xsl:text>
|
|
1070
|
+
</xsl:if>
|
|
1071
|
+
<span>
|
|
1072
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1073
|
+
<xsl:call-template name="id.attribute"/>
|
|
1074
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1075
|
+
</span>
|
|
1076
|
+
</xsl:template>
|
|
1077
|
+
|
|
1078
|
+
<xsl:template match="d:exceptionname" mode="cpp">
|
|
1079
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'exceptionname'">
|
|
1080
|
+
<xsl:text>, </xsl:text>
|
|
1081
|
+
</xsl:if>
|
|
1082
|
+
<span>
|
|
1083
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1084
|
+
<xsl:call-template name="id.attribute"/>
|
|
1085
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1086
|
+
</span>
|
|
1087
|
+
</xsl:template>
|
|
1088
|
+
|
|
1089
|
+
<xsl:template match="d:fieldsynopsis" mode="cpp">
|
|
1090
|
+
<code>
|
|
1091
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1092
|
+
<xsl:call-template name="id.attribute"/>
|
|
1093
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
1094
|
+
<xsl:text>  </xsl:text>
|
|
1095
|
+
</xsl:if>
|
|
1096
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1097
|
+
<xsl:text>;</xsl:text>
|
|
1098
|
+
</code>
|
|
1099
|
+
<xsl:call-template name="synop-break"/>
|
|
1100
|
+
</xsl:template>
|
|
1101
|
+
|
|
1102
|
+
<xsl:template match="d:type" mode="cpp">
|
|
1103
|
+
<span>
|
|
1104
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1105
|
+
<xsl:call-template name="id.attribute"/>
|
|
1106
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1107
|
+
<xsl:text> </xsl:text>
|
|
1108
|
+
</span>
|
|
1109
|
+
</xsl:template>
|
|
1110
|
+
|
|
1111
|
+
<xsl:template match="d:varname" mode="cpp">
|
|
1112
|
+
<span>
|
|
1113
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1114
|
+
<xsl:call-template name="id.attribute"/>
|
|
1115
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1116
|
+
<xsl:text> </xsl:text>
|
|
1117
|
+
</span>
|
|
1118
|
+
</xsl:template>
|
|
1119
|
+
|
|
1120
|
+
<xsl:template match="d:initializer" mode="cpp">
|
|
1121
|
+
<span>
|
|
1122
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1123
|
+
<xsl:call-template name="id.attribute"/>
|
|
1124
|
+
<xsl:text>= </xsl:text>
|
|
1125
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1126
|
+
</span>
|
|
1127
|
+
</xsl:template>
|
|
1128
|
+
|
|
1129
|
+
<xsl:template match="d:void" mode="cpp">
|
|
1130
|
+
<span>
|
|
1131
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1132
|
+
<xsl:call-template name="id.attribute"/>
|
|
1133
|
+
<xsl:text>void </xsl:text>
|
|
1134
|
+
</span>
|
|
1135
|
+
</xsl:template>
|
|
1136
|
+
|
|
1137
|
+
<xsl:template match="d:methodname" mode="cpp">
|
|
1138
|
+
<span>
|
|
1139
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1140
|
+
<xsl:call-template name="id.attribute"/>
|
|
1141
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1142
|
+
</span>
|
|
1143
|
+
</xsl:template>
|
|
1144
|
+
|
|
1145
|
+
<xsl:template match="d:methodparam" mode="cpp">
|
|
1146
|
+
<xsl:if test="preceding-sibling::d:methodparam">
|
|
1147
|
+
<xsl:text>, </xsl:text>
|
|
1148
|
+
</xsl:if>
|
|
1149
|
+
<span>
|
|
1150
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1151
|
+
<xsl:call-template name="id.attribute"/>
|
|
1152
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1153
|
+
</span>
|
|
1154
|
+
</xsl:template>
|
|
1155
|
+
|
|
1156
|
+
<xsl:template match="d:parameter" mode="cpp">
|
|
1157
|
+
<span>
|
|
1158
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1159
|
+
<xsl:call-template name="id.attribute"/>
|
|
1160
|
+
<xsl:apply-templates mode="cpp"/>
|
|
1161
|
+
</span>
|
|
1162
|
+
</xsl:template>
|
|
1163
|
+
|
|
1164
|
+
<xsl:template mode="cpp" match="d:constructorsynopsis|d:destructorsynopsis|d:methodsynopsis">
|
|
1165
|
+
<xsl:variable name="start-modifiers" select="d:modifier[following-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1166
|
+
<xsl:variable name="notmod" select="*[local-name(.) != 'modifier']"/>
|
|
1167
|
+
<xsl:variable name="end-modifiers" select="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1168
|
+
|
|
1169
|
+
<code>
|
|
1170
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1171
|
+
<xsl:call-template name="id.attribute"/>
|
|
1172
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
1173
|
+
<xsl:text>  </xsl:text>
|
|
1174
|
+
</xsl:if>
|
|
1175
|
+
<xsl:apply-templates select="$start-modifiers" mode="cpp"/>
|
|
1176
|
+
|
|
1177
|
+
<!-- type -->
|
|
1178
|
+
<xsl:if test="local-name($notmod[1]) != 'methodname'">
|
|
1179
|
+
<xsl:apply-templates select="$notmod[1]" mode="cpp"/>
|
|
1180
|
+
</xsl:if>
|
|
1181
|
+
|
|
1182
|
+
<xsl:apply-templates select="d:methodname" mode="cpp"/>
|
|
1183
|
+
<xsl:text>(</xsl:text>
|
|
1184
|
+
<xsl:apply-templates select="d:methodparam" mode="cpp"/>
|
|
1185
|
+
<xsl:text>)</xsl:text>
|
|
1186
|
+
<xsl:if test="d:exceptionname">
|
|
1187
|
+
<br/>
|
|
1188
|
+
<xsl:text>    throws </xsl:text>
|
|
1189
|
+
<xsl:apply-templates select="d:exceptionname" mode="cpp"/>
|
|
1190
|
+
</xsl:if>
|
|
1191
|
+
<xsl:if test="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]">
|
|
1192
|
+
<xsl:text> </xsl:text>
|
|
1193
|
+
<xsl:apply-templates select="$end-modifiers" mode="cpp"/>
|
|
1194
|
+
</xsl:if>
|
|
1195
|
+
<xsl:text>;</xsl:text>
|
|
1196
|
+
</code>
|
|
1197
|
+
<xsl:call-template name="synop-break"/>
|
|
1198
|
+
</xsl:template>
|
|
1199
|
+
|
|
1200
|
+
<!-- ===== IDL ========================================================= -->
|
|
1201
|
+
|
|
1202
|
+
<xsl:template match="d:classsynopsis" mode="idl">
|
|
1203
|
+
<pre>
|
|
1204
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1205
|
+
<xsl:call-template name="id.attribute"/>
|
|
1206
|
+
<xsl:text>interface </xsl:text>
|
|
1207
|
+
<xsl:apply-templates select="d:ooclass[1]" mode="idl"/>
|
|
1208
|
+
<xsl:if test="d:ooclass[preceding-sibling::*]">
|
|
1209
|
+
<xsl:text>: </xsl:text>
|
|
1210
|
+
<xsl:apply-templates select="d:ooclass[preceding-sibling::*]" mode="idl"/>
|
|
1211
|
+
<xsl:if test="d:oointerface|d:ooexception">
|
|
1212
|
+
<br/>
|
|
1213
|
+
<xsl:text>    </xsl:text>
|
|
1214
|
+
</xsl:if>
|
|
1215
|
+
</xsl:if>
|
|
1216
|
+
<xsl:if test="d:oointerface">
|
|
1217
|
+
<xsl:text> implements</xsl:text>
|
|
1218
|
+
<xsl:apply-templates select="d:oointerface" mode="idl"/>
|
|
1219
|
+
<xsl:if test="d:ooexception">
|
|
1220
|
+
<br/>
|
|
1221
|
+
<xsl:text>    </xsl:text>
|
|
1222
|
+
</xsl:if>
|
|
1223
|
+
</xsl:if>
|
|
1224
|
+
<xsl:if test="d:ooexception">
|
|
1225
|
+
<xsl:text> throws</xsl:text>
|
|
1226
|
+
<xsl:apply-templates select="d:ooexception" mode="idl"/>
|
|
1227
|
+
</xsl:if>
|
|
1228
|
+
<xsl:text> {</xsl:text>
|
|
1229
|
+
<br/>
|
|
1230
|
+
<xsl:apply-templates select="d:constructorsynopsis |d:destructorsynopsis |d:fieldsynopsis |d:methodsynopsis |d:classsynopsisinfo" mode="idl"/>
|
|
1231
|
+
<xsl:text>}</xsl:text>
|
|
1232
|
+
</pre>
|
|
1233
|
+
</xsl:template>
|
|
1234
|
+
|
|
1235
|
+
<xsl:template match="d:classsynopsisinfo" mode="idl">
|
|
1236
|
+
<xsl:apply-templates mode="idl"/>
|
|
1237
|
+
</xsl:template>
|
|
1238
|
+
|
|
1239
|
+
<xsl:template match="d:ooclass|d:oointerface|d:ooexception" mode="idl">
|
|
1240
|
+
<xsl:if test="preceding-sibling::*">
|
|
1241
|
+
<xsl:text>, </xsl:text>
|
|
1242
|
+
</xsl:if>
|
|
1243
|
+
<span>
|
|
1244
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1245
|
+
<xsl:call-template name="id.attribute"/>
|
|
1246
|
+
<xsl:apply-templates mode="idl"/>
|
|
1247
|
+
</span>
|
|
1248
|
+
</xsl:template>
|
|
1249
|
+
|
|
1250
|
+
<xsl:template match="d:modifier|d:package" mode="idl">
|
|
1251
|
+
<span>
|
|
1252
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1253
|
+
<xsl:call-template name="id.attribute"/>
|
|
1254
|
+
<xsl:apply-templates mode="idl"/>
|
|
1255
|
+
<xsl:if test="following-sibling::*">
|
|
1256
|
+
<xsl:text> </xsl:text>
|
|
1257
|
+
</xsl:if>
|
|
1258
|
+
</span>
|
|
1259
|
+
</xsl:template>
|
|
1260
|
+
|
|
1261
|
+
<xsl:template match="d:classname" mode="idl">
|
|
1262
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'classname'">
|
|
1263
|
+
<xsl:text>, </xsl:text>
|
|
1264
|
+
</xsl:if>
|
|
1265
|
+
<span>
|
|
1266
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1267
|
+
<xsl:call-template name="id.attribute"/>
|
|
1268
|
+
<xsl:apply-templates mode="idl"/>
|
|
1269
|
+
</span>
|
|
1270
|
+
</xsl:template>
|
|
1271
|
+
|
|
1272
|
+
<xsl:template match="d:interfacename" mode="idl">
|
|
1273
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'interfacename'">
|
|
1274
|
+
<xsl:text>, </xsl:text>
|
|
1275
|
+
</xsl:if>
|
|
1276
|
+
<span>
|
|
1277
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1278
|
+
<xsl:call-template name="id.attribute"/>
|
|
1279
|
+
<xsl:apply-templates mode="idl"/>
|
|
1280
|
+
</span>
|
|
1281
|
+
</xsl:template>
|
|
1282
|
+
|
|
1283
|
+
<xsl:template match="d:exceptionname" mode="idl">
|
|
1284
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'exceptionname'">
|
|
1285
|
+
<xsl:text>, </xsl:text>
|
|
1286
|
+
</xsl:if>
|
|
1287
|
+
<span>
|
|
1288
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1289
|
+
<xsl:call-template name="id.attribute"/>
|
|
1290
|
+
<xsl:apply-templates mode="idl"/>
|
|
1291
|
+
</span>
|
|
1292
|
+
</xsl:template>
|
|
1293
|
+
|
|
1294
|
+
<xsl:template match="d:fieldsynopsis" mode="idl">
|
|
1295
|
+
<code>
|
|
1296
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1297
|
+
<xsl:call-template name="id.attribute"/>
|
|
1298
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
1299
|
+
<xsl:text>  </xsl:text>
|
|
1300
|
+
</xsl:if>
|
|
1301
|
+
<xsl:apply-templates mode="idl"/>
|
|
1302
|
+
<xsl:text>;</xsl:text>
|
|
1303
|
+
</code>
|
|
1304
|
+
<xsl:call-template name="synop-break"/>
|
|
1305
|
+
</xsl:template>
|
|
1306
|
+
|
|
1307
|
+
<xsl:template match="d:type" mode="idl">
|
|
1308
|
+
<span>
|
|
1309
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1310
|
+
<xsl:call-template name="id.attribute"/>
|
|
1311
|
+
<xsl:apply-templates mode="idl"/>
|
|
1312
|
+
<xsl:text> </xsl:text>
|
|
1313
|
+
</span>
|
|
1314
|
+
</xsl:template>
|
|
1315
|
+
|
|
1316
|
+
<xsl:template match="d:varname" mode="idl">
|
|
1317
|
+
<span>
|
|
1318
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1319
|
+
<xsl:call-template name="id.attribute"/>
|
|
1320
|
+
<xsl:apply-templates mode="idl"/>
|
|
1321
|
+
<xsl:text> </xsl:text>
|
|
1322
|
+
</span>
|
|
1323
|
+
</xsl:template>
|
|
1324
|
+
|
|
1325
|
+
<xsl:template match="d:initializer" mode="idl">
|
|
1326
|
+
<span>
|
|
1327
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1328
|
+
<xsl:call-template name="id.attribute"/>
|
|
1329
|
+
<xsl:text>= </xsl:text>
|
|
1330
|
+
<xsl:apply-templates mode="idl"/>
|
|
1331
|
+
</span>
|
|
1332
|
+
</xsl:template>
|
|
1333
|
+
|
|
1334
|
+
<xsl:template match="d:void" mode="idl">
|
|
1335
|
+
<span>
|
|
1336
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1337
|
+
<xsl:call-template name="id.attribute"/>
|
|
1338
|
+
<xsl:text>void </xsl:text>
|
|
1339
|
+
</span>
|
|
1340
|
+
</xsl:template>
|
|
1341
|
+
|
|
1342
|
+
<xsl:template match="d:methodname" mode="idl">
|
|
1343
|
+
<span>
|
|
1344
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1345
|
+
<xsl:call-template name="id.attribute"/>
|
|
1346
|
+
<xsl:apply-templates mode="idl"/>
|
|
1347
|
+
</span>
|
|
1348
|
+
</xsl:template>
|
|
1349
|
+
|
|
1350
|
+
<xsl:template match="d:methodparam" mode="idl">
|
|
1351
|
+
<xsl:if test="preceding-sibling::d:methodparam">
|
|
1352
|
+
<xsl:text>, </xsl:text>
|
|
1353
|
+
</xsl:if>
|
|
1354
|
+
<span>
|
|
1355
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1356
|
+
<xsl:call-template name="id.attribute"/>
|
|
1357
|
+
<xsl:apply-templates mode="idl"/>
|
|
1358
|
+
</span>
|
|
1359
|
+
</xsl:template>
|
|
1360
|
+
|
|
1361
|
+
<xsl:template match="d:parameter" mode="idl">
|
|
1362
|
+
<span>
|
|
1363
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1364
|
+
<xsl:call-template name="id.attribute"/>
|
|
1365
|
+
<xsl:apply-templates mode="idl"/>
|
|
1366
|
+
</span>
|
|
1367
|
+
</xsl:template>
|
|
1368
|
+
|
|
1369
|
+
<xsl:template mode="idl" match="d:constructorsynopsis|d:destructorsynopsis|d:methodsynopsis">
|
|
1370
|
+
<xsl:variable name="start-modifiers" select="d:modifier[following-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1371
|
+
<xsl:variable name="notmod" select="*[local-name(.) != 'modifier']"/>
|
|
1372
|
+
<xsl:variable name="end-modifiers" select="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1373
|
+
<code>
|
|
1374
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1375
|
+
<xsl:call-template name="id.attribute"/>
|
|
1376
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
1377
|
+
<xsl:text>  </xsl:text>
|
|
1378
|
+
</xsl:if>
|
|
1379
|
+
<xsl:apply-templates select="$start-modifiers" mode="idl"/>
|
|
1380
|
+
|
|
1381
|
+
<!-- type -->
|
|
1382
|
+
<xsl:if test="local-name($notmod[1]) != 'methodname'">
|
|
1383
|
+
<xsl:apply-templates select="$notmod[1]" mode="idl"/>
|
|
1384
|
+
</xsl:if>
|
|
1385
|
+
|
|
1386
|
+
<xsl:apply-templates select="d:methodname" mode="idl"/>
|
|
1387
|
+
<xsl:text>(</xsl:text>
|
|
1388
|
+
<xsl:apply-templates select="d:methodparam" mode="idl"/>
|
|
1389
|
+
<xsl:text>)</xsl:text>
|
|
1390
|
+
<xsl:if test="d:exceptionname">
|
|
1391
|
+
<br/>
|
|
1392
|
+
<xsl:text>    raises(</xsl:text>
|
|
1393
|
+
<xsl:apply-templates select="d:exceptionname" mode="idl"/>
|
|
1394
|
+
<xsl:text>)</xsl:text>
|
|
1395
|
+
</xsl:if>
|
|
1396
|
+
<xsl:if test="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]">
|
|
1397
|
+
<xsl:text> </xsl:text>
|
|
1398
|
+
<xsl:apply-templates select="$end-modifiers" mode="idl"/>
|
|
1399
|
+
</xsl:if>
|
|
1400
|
+
<xsl:text>;</xsl:text>
|
|
1401
|
+
</code>
|
|
1402
|
+
<xsl:call-template name="synop-break"/>
|
|
1403
|
+
</xsl:template>
|
|
1404
|
+
|
|
1405
|
+
<!-- ===== Perl ======================================================== -->
|
|
1406
|
+
|
|
1407
|
+
<xsl:template match="d:classsynopsis" mode="perl">
|
|
1408
|
+
<pre>
|
|
1409
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1410
|
+
<xsl:call-template name="id.attribute"/>
|
|
1411
|
+
<xsl:text>package </xsl:text>
|
|
1412
|
+
<xsl:apply-templates select="d:ooclass[1]" mode="perl"/>
|
|
1413
|
+
<xsl:text>;</xsl:text>
|
|
1414
|
+
<br/>
|
|
1415
|
+
|
|
1416
|
+
<xsl:if test="d:ooclass[preceding-sibling::*]">
|
|
1417
|
+
<xsl:text>@ISA = (</xsl:text>
|
|
1418
|
+
<xsl:apply-templates select="d:ooclass[preceding-sibling::*]" mode="perl"/>
|
|
1419
|
+
<xsl:text>);</xsl:text>
|
|
1420
|
+
<br/>
|
|
1421
|
+
</xsl:if>
|
|
1422
|
+
|
|
1423
|
+
<xsl:apply-templates select="d:constructorsynopsis |d:destructorsynopsis |d:fieldsynopsis |d:methodsynopsis |d:classsynopsisinfo" mode="perl"/>
|
|
1424
|
+
</pre>
|
|
1425
|
+
</xsl:template>
|
|
1426
|
+
|
|
1427
|
+
<xsl:template match="d:classsynopsisinfo" mode="perl">
|
|
1428
|
+
<xsl:apply-templates mode="perl"/>
|
|
1429
|
+
</xsl:template>
|
|
1430
|
+
|
|
1431
|
+
<xsl:template match="d:ooclass|d:oointerface|d:ooexception" mode="perl">
|
|
1432
|
+
<xsl:if test="preceding-sibling::*">
|
|
1433
|
+
<xsl:text>, </xsl:text>
|
|
1434
|
+
</xsl:if>
|
|
1435
|
+
<span>
|
|
1436
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1437
|
+
<xsl:call-template name="id.attribute"/>
|
|
1438
|
+
<xsl:apply-templates mode="perl"/>
|
|
1439
|
+
</span>
|
|
1440
|
+
</xsl:template>
|
|
1441
|
+
|
|
1442
|
+
<xsl:template match="d:modifier|d:package" mode="perl">
|
|
1443
|
+
<span>
|
|
1444
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1445
|
+
<xsl:call-template name="id.attribute"/>
|
|
1446
|
+
<xsl:apply-templates mode="perl"/>
|
|
1447
|
+
<xsl:if test="following-sibling::*">
|
|
1448
|
+
<xsl:text> </xsl:text>
|
|
1449
|
+
</xsl:if>
|
|
1450
|
+
</span>
|
|
1451
|
+
</xsl:template>
|
|
1452
|
+
|
|
1453
|
+
<xsl:template match="d:classname" mode="perl">
|
|
1454
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'classname'">
|
|
1455
|
+
<xsl:text>, </xsl:text>
|
|
1456
|
+
</xsl:if>
|
|
1457
|
+
<span>
|
|
1458
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1459
|
+
<xsl:call-template name="id.attribute"/>
|
|
1460
|
+
<xsl:apply-templates mode="perl"/>
|
|
1461
|
+
</span>
|
|
1462
|
+
</xsl:template>
|
|
1463
|
+
|
|
1464
|
+
<xsl:template match="d:interfacename" mode="perl">
|
|
1465
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'interfacename'">
|
|
1466
|
+
<xsl:text>, </xsl:text>
|
|
1467
|
+
</xsl:if>
|
|
1468
|
+
<span>
|
|
1469
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1470
|
+
<xsl:call-template name="id.attribute"/>
|
|
1471
|
+
<xsl:apply-templates mode="perl"/>
|
|
1472
|
+
</span>
|
|
1473
|
+
</xsl:template>
|
|
1474
|
+
|
|
1475
|
+
<xsl:template match="d:exceptionname" mode="perl">
|
|
1476
|
+
<xsl:if test="local-name(preceding-sibling::*[1]) = 'exceptionname'">
|
|
1477
|
+
<xsl:text>, </xsl:text>
|
|
1478
|
+
</xsl:if>
|
|
1479
|
+
<span>
|
|
1480
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1481
|
+
<xsl:call-template name="id.attribute"/>
|
|
1482
|
+
<xsl:apply-templates mode="perl"/>
|
|
1483
|
+
</span>
|
|
1484
|
+
</xsl:template>
|
|
1485
|
+
|
|
1486
|
+
<xsl:template match="d:fieldsynopsis" mode="perl">
|
|
1487
|
+
<code>
|
|
1488
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1489
|
+
<xsl:call-template name="id.attribute"/>
|
|
1490
|
+
<xsl:if test="parent::d:classsynopsis">
|
|
1491
|
+
<xsl:text>  </xsl:text>
|
|
1492
|
+
</xsl:if>
|
|
1493
|
+
<xsl:apply-templates mode="perl"/>
|
|
1494
|
+
<xsl:text>;</xsl:text>
|
|
1495
|
+
</code>
|
|
1496
|
+
<xsl:call-template name="synop-break"/>
|
|
1497
|
+
</xsl:template>
|
|
1498
|
+
|
|
1499
|
+
<xsl:template match="d:type" mode="perl">
|
|
1500
|
+
<span>
|
|
1501
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1502
|
+
<xsl:call-template name="id.attribute"/>
|
|
1503
|
+
<xsl:apply-templates mode="perl"/>
|
|
1504
|
+
<xsl:text> </xsl:text>
|
|
1505
|
+
</span>
|
|
1506
|
+
</xsl:template>
|
|
1507
|
+
|
|
1508
|
+
<xsl:template match="d:varname" mode="perl">
|
|
1509
|
+
<span>
|
|
1510
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1511
|
+
<xsl:call-template name="id.attribute"/>
|
|
1512
|
+
<xsl:apply-templates mode="perl"/>
|
|
1513
|
+
<xsl:text> </xsl:text>
|
|
1514
|
+
</span>
|
|
1515
|
+
</xsl:template>
|
|
1516
|
+
|
|
1517
|
+
<xsl:template match="d:initializer" mode="perl">
|
|
1518
|
+
<span>
|
|
1519
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1520
|
+
<xsl:call-template name="id.attribute"/>
|
|
1521
|
+
<xsl:text>= </xsl:text>
|
|
1522
|
+
<xsl:apply-templates mode="perl"/>
|
|
1523
|
+
</span>
|
|
1524
|
+
</xsl:template>
|
|
1525
|
+
|
|
1526
|
+
<xsl:template match="d:void" mode="perl">
|
|
1527
|
+
<span>
|
|
1528
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1529
|
+
<xsl:call-template name="id.attribute"/>
|
|
1530
|
+
<xsl:text>void </xsl:text>
|
|
1531
|
+
</span>
|
|
1532
|
+
</xsl:template>
|
|
1533
|
+
|
|
1534
|
+
<xsl:template match="d:methodname" mode="perl">
|
|
1535
|
+
<span>
|
|
1536
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1537
|
+
<xsl:call-template name="id.attribute"/>
|
|
1538
|
+
<xsl:apply-templates mode="perl"/>
|
|
1539
|
+
</span>
|
|
1540
|
+
</xsl:template>
|
|
1541
|
+
|
|
1542
|
+
<xsl:template match="d:methodparam" mode="perl">
|
|
1543
|
+
<xsl:if test="preceding-sibling::d:methodparam">
|
|
1544
|
+
<xsl:text>, </xsl:text>
|
|
1545
|
+
</xsl:if>
|
|
1546
|
+
<span>
|
|
1547
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1548
|
+
<xsl:call-template name="id.attribute"/>
|
|
1549
|
+
<xsl:apply-templates mode="perl"/>
|
|
1550
|
+
</span>
|
|
1551
|
+
</xsl:template>
|
|
1552
|
+
|
|
1553
|
+
<xsl:template match="d:parameter" mode="perl">
|
|
1554
|
+
<span>
|
|
1555
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1556
|
+
<xsl:call-template name="id.attribute"/>
|
|
1557
|
+
<xsl:apply-templates mode="perl"/>
|
|
1558
|
+
</span>
|
|
1559
|
+
</xsl:template>
|
|
1560
|
+
|
|
1561
|
+
<xsl:template mode="perl" match="d:constructorsynopsis|d:destructorsynopsis|d:methodsynopsis">
|
|
1562
|
+
<xsl:variable name="start-modifiers" select="d:modifier[following-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1563
|
+
<xsl:variable name="notmod" select="*[local-name(.) != 'modifier']"/>
|
|
1564
|
+
<xsl:variable name="end-modifiers" select="d:modifier[preceding-sibling::*[local-name(.) != 'modifier']]"/>
|
|
1565
|
+
|
|
1566
|
+
<code>
|
|
1567
|
+
<xsl:apply-templates select="." mode="common.html.attributes"/>
|
|
1568
|
+
<xsl:call-template name="id.attribute"/>
|
|
1569
|
+
<xsl:text>sub </xsl:text>
|
|
1570
|
+
|
|
1571
|
+
<xsl:apply-templates select="d:methodname" mode="perl"/>
|
|
1572
|
+
<xsl:text> { ... };</xsl:text>
|
|
1573
|
+
</code>
|
|
1574
|
+
<xsl:call-template name="synop-break"/>
|
|
1575
|
+
</xsl:template>
|
|
1576
|
+
|
|
1577
|
+
<!-- Used when not occurring as a child of classsynopsis -->
|
|
1578
|
+
<xsl:template match="d:ooclass|d:oointerface|d:ooexception">
|
|
1579
|
+
<xsl:apply-templates/>
|
|
1580
|
+
</xsl:template>
|
|
1581
|
+
|
|
1582
|
+
<!-- ==================================================================== -->
|
|
1583
|
+
|
|
1584
|
+
<!-- * DocBook 5 allows linking elements (link, olink, and xref) -->
|
|
1585
|
+
<!-- * within the OO *synopsis elements (classsynopsis, fieldsynopsis, -->
|
|
1586
|
+
<!-- * methodsynopsis, constructorsynopsis, destructorsynopsis) and -->
|
|
1587
|
+
<!-- * their children. So we need to have mode="java|cpp|idl|perl" -->
|
|
1588
|
+
<!-- * per-mode matches for those linking elements in order for them -->
|
|
1589
|
+
<!-- * to be processed as expected. -->
|
|
1590
|
+
|
|
1591
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="java">
|
|
1592
|
+
<xsl:apply-templates select="."/>
|
|
1593
|
+
</xsl:template>
|
|
1594
|
+
|
|
1595
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="cpp">
|
|
1596
|
+
<xsl:apply-templates select="."/>
|
|
1597
|
+
</xsl:template>
|
|
1598
|
+
|
|
1599
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="idl">
|
|
1600
|
+
<xsl:apply-templates select="."/>
|
|
1601
|
+
</xsl:template>
|
|
1602
|
+
|
|
1603
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="perl">
|
|
1604
|
+
<xsl:apply-templates select="."/>
|
|
1605
|
+
</xsl:template>
|
|
1606
|
+
|
|
1607
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="ansi-nontabular">
|
|
1608
|
+
<xsl:apply-templates select="."/>
|
|
1609
|
+
</xsl:template>
|
|
1610
|
+
|
|
1611
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="ansi-tabular">
|
|
1612
|
+
<xsl:apply-templates select="."/>
|
|
1613
|
+
</xsl:template>
|
|
1614
|
+
|
|
1615
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="kr-nontabular">
|
|
1616
|
+
<xsl:apply-templates select="."/>
|
|
1617
|
+
</xsl:template>
|
|
1618
|
+
|
|
1619
|
+
<xsl:template match="d:link|d:olink|d:xref" mode="kr-tabular">
|
|
1620
|
+
<xsl:apply-templates select="."/>
|
|
1621
|
+
</xsl:template>
|
|
1622
|
+
|
|
1623
|
+
</xsl:stylesheet>
|