onvif-python 0.0.1__py3-none-any.whl

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.
Files changed (106) hide show
  1. onvif/__init__.py +13 -0
  2. onvif/client.py +485 -0
  3. onvif/operator.py +130 -0
  4. onvif/services/__init__.py +75 -0
  5. onvif/services/accesscontrol.py +105 -0
  6. onvif/services/accessrules.py +47 -0
  7. onvif/services/actionengine.py +46 -0
  8. onvif/services/analytics/analytics.py +60 -0
  9. onvif/services/analytics/ruleengine.py +44 -0
  10. onvif/services/analyticsdevice.py +122 -0
  11. onvif/services/appmgmt.py +40 -0
  12. onvif/services/authenticationbehavior.py +83 -0
  13. onvif/services/credential.py +159 -0
  14. onvif/services/deviceio.py +165 -0
  15. onvif/services/devicemgmt.py +410 -0
  16. onvif/services/display.py +62 -0
  17. onvif/services/doorcontrol.py +93 -0
  18. onvif/services/events/events.py +41 -0
  19. onvif/services/events/notification.py +34 -0
  20. onvif/services/events/pullpoint.py +29 -0
  21. onvif/services/events/subscription.py +21 -0
  22. onvif/services/imaging.py +62 -0
  23. onvif/services/media.py +424 -0
  24. onvif/services/media2.py +310 -0
  25. onvif/services/provisioning.py +50 -0
  26. onvif/services/ptz.py +187 -0
  27. onvif/services/receiver.py +46 -0
  28. onvif/services/recording.py +136 -0
  29. onvif/services/replay.py +30 -0
  30. onvif/services/schedule.py +82 -0
  31. onvif/services/search.py +149 -0
  32. onvif/services/security/advancedsecurity.py +19 -0
  33. onvif/services/security/authorizationserver.py +31 -0
  34. onvif/services/security/dot1x.py +42 -0
  35. onvif/services/security/jwt.py +21 -0
  36. onvif/services/security/keystore.py +208 -0
  37. onvif/services/security/mediasigning.py +30 -0
  38. onvif/services/security/tlsserver.py +82 -0
  39. onvif/services/thermal.py +54 -0
  40. onvif/services/uplink.py +28 -0
  41. onvif/utils/__init__.py +4 -0
  42. onvif/utils/exceptions.py +33 -0
  43. onvif/utils/wsdl.py +297 -0
  44. onvif/wsdl/ver10/accesscontrol/wsdl/index.html +7 -0
  45. onvif/wsdl/ver10/accessrules/wsdl/accessrules.wsdl +702 -0
  46. onvif/wsdl/ver10/accessrules/wsdl/index.html +7 -0
  47. onvif/wsdl/ver10/actionengine.wsdl +1265 -0
  48. onvif/wsdl/ver10/advancedsecurity/wsdl/advancedsecurity.wsdl +4159 -0
  49. onvif/wsdl/ver10/advancedsecurity/wsdl/index.html +7 -0
  50. onvif/wsdl/ver10/analyticsdevice.wsdl +709 -0
  51. onvif/wsdl/ver10/appmgmt/wsdl/appmgmt.wsdl +502 -0
  52. onvif/wsdl/ver10/appmgmt/wsdl/index.html +7 -0
  53. onvif/wsdl/ver10/authenticationbehavior/wsdl/authenticationbehavior.wsdl +1382 -0
  54. onvif/wsdl/ver10/authenticationbehavior/wsdl/index.html +7 -0
  55. onvif/wsdl/ver10/credential/wsdl/credential.wsdl +2018 -0
  56. onvif/wsdl/ver10/credential/wsdl/index.html +7 -0
  57. onvif/wsdl/ver10/device/wsdl/devicemgmt.wsdl +4623 -0
  58. onvif/wsdl/ver10/deviceio.wsdl +1414 -0
  59. onvif/wsdl/ver10/display/display.wsdl +383 -0
  60. onvif/wsdl/ver10/display/wsdl/index.htm +383 -0
  61. onvif/wsdl/ver10/display.wsdl +521 -0
  62. onvif/wsdl/ver10/doorcontrol/wsdl/index.html +7 -0
  63. onvif/wsdl/ver10/events/wsdl/bw-2-vs-mod.wsdl +449 -0
  64. onvif/wsdl/ver10/events/wsdl/event-vs.wsdl +947 -0
  65. onvif/wsdl/ver10/events/wsdl/event.wsdl +947 -0
  66. onvif/wsdl/ver10/events/wsdl/index.html +7 -0
  67. onvif/wsdl/ver10/federatedsearch.wsdl +344 -0
  68. onvif/wsdl/ver10/media/wsdl/media.wsdl +3684 -0
  69. onvif/wsdl/ver10/pacs/accesscontrol.wsdl +1942 -0
  70. onvif/wsdl/ver10/pacs/doorcontrol.wsdl +1792 -0
  71. onvif/wsdl/ver10/pacs/types.xsd +181 -0
  72. onvif/wsdl/ver10/provisioning/wsdl/provisioning.wsdl +588 -0
  73. onvif/wsdl/ver10/receiver.wsdl +398 -0
  74. onvif/wsdl/ver10/recording.wsdl +1231 -0
  75. onvif/wsdl/ver10/replay.wsdl +221 -0
  76. onvif/wsdl/ver10/schedule/wsdl/index.html +7 -0
  77. onvif/wsdl/ver10/schedule/wsdl/schedule.wsdl +1383 -0
  78. onvif/wsdl/ver10/schema/common.xsd +422 -0
  79. onvif/wsdl/ver10/schema/metadatastream.xsd +520 -0
  80. onvif/wsdl/ver10/schema/onvif.xsd +9251 -0
  81. onvif/wsdl/ver10/search.wsdl +882 -0
  82. onvif/wsdl/ver10/thermal/wsdl/index.html +7 -0
  83. onvif/wsdl/ver10/thermal/wsdl/thermal.wsdl +777 -0
  84. onvif/wsdl/ver10/topics/topicns.xml +13 -0
  85. onvif/wsdl/ver10/uplink/wsdl/index.html +7 -0
  86. onvif/wsdl/ver10/uplink/wsdl/uplink.wsdl +256 -0
  87. onvif/wsdl/ver20/analytics/humanbody.xsd +490 -0
  88. onvif/wsdl/ver20/analytics/humanface.xsd +501 -0
  89. onvif/wsdl/ver20/analytics/index.html +7 -0
  90. onvif/wsdl/ver20/analytics/radiometry.xsd +389 -0
  91. onvif/wsdl/ver20/analytics/rules.xsd +127 -0
  92. onvif/wsdl/ver20/analytics/wsdl/analytics.wsdl +757 -0
  93. onvif/wsdl/ver20/analytics/wsdl/index.html +7 -0
  94. onvif/wsdl/ver20/imaging/wsdl/imaging.wsdl +603 -0
  95. onvif/wsdl/ver20/media/wsdl/index.html +7 -0
  96. onvif/wsdl/ver20/media/wsdl/media.wsdl +2862 -0
  97. onvif/wsdl/ver20/ptz/wsdl/ptz.wsdl +1450 -0
  98. onvif/wsdl/ver20/util/federated_search_documentation.html +1647 -0
  99. onvif/wsdl/ver20/util/fedsearch-docu-viewer.xsl +8 -0
  100. onvif/wsdl/ver20/util/onvif-wsdl-viewer.xsl +2580 -0
  101. onvif/wsdl/ver20/util/operationIndex.html +97 -0
  102. onvif_python-0.0.1.dist-info/METADATA +381 -0
  103. onvif_python-0.0.1.dist-info/RECORD +106 -0
  104. onvif_python-0.0.1.dist-info/WHEEL +5 -0
  105. onvif_python-0.0.1.dist-info/licenses/LICENSE.md +21 -0
  106. onvif_python-0.0.1.dist-info/top_level.txt +1 -0
@@ -0,0 +1,2580 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+
3
+ <!--
4
+ /**
5
+ * Licensed to the Apache Software Foundation (ASF) under one or more
6
+ * contributor license agreements. See the NOTICE file distributed with
7
+ * this work for additional information regarding copyright ownership.
8
+ * The ASF licenses this file to You under the Apache License, Version 2.0
9
+ * (the "License"); you may not use this file except in compliance with
10
+ * the License. You may obtain a copy of the License at
11
+ *
12
+ * http://www.apache.org/licenses/LICENSE-2.0
13
+ *
14
+ * Unless required by applicable law or agreed to in writing, software
15
+ * distributed under the License is distributed on an "AS IS" BASIS,
16
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
+ * See the License for the specific language governing permissions and
18
+ * limitations under the License.
19
+ */
20
+ -->
21
+
22
+
23
+ <!--
24
+ * ====================================================================
25
+ * wsdl-viewer.xsl
26
+ * Version: 3.1.02
27
+ *
28
+ * URL: http://tomi.vanek.sk/xml/wsdl-viewer.xsl
29
+ *
30
+ * Author: tomi vanek
31
+ * Inspiration: Uche Ogbui - WSDL processing with XSLT
32
+ * http://www-106.ibm.com/developerworks/library/ws-trans/index.html
33
+ * ====================================================================
34
+ -->
35
+
36
+
37
+ <!--
38
+ * ====================================================================
39
+ * Description:
40
+ * wsdl-viewer.xsl is a lightweight XSLT 1.0 transformation with minimal
41
+ * usage of any hacks that extend the possibilities of the transformation
42
+ * over the XSLT 1.0 constraints but eventually would harm the engine independance.
43
+ *
44
+ * The transformation has to run even in the browser offered XSLT engines
45
+ * (tested in IE 6 and Firefox) and in ANT "batch" processing.
46
+ * ====================================================================
47
+ * How to add the HTML look to a WSDL:
48
+ * <?xml version="1.0" encoding="utf-8"?>
49
+ * <?xml-stylesheet type="text/xsl" href="wsdl-viewer.xsl"?>
50
+ * <wsdl:definitions ...>
51
+ * ... Here is the service declaration
52
+ * </wsdl:definitions>
53
+ *
54
+ * The web-browsers (in Windows) are not able by default automatically recognize
55
+ * the ".wsdl" file type (suffix). For the type recognition the WSDL file has
56
+ * to be renamed by adding the suffix ".xml" - i.e. "myservice.wsdl.xml".
57
+ * ====================================================================
58
+ * Constraints:
59
+ * 1. Processing of imported files
60
+ * 1.1 Only 1 imported WSDL and 1 imported XSD is processed
61
+ * (well, maybe with a smarter recursive strategy this restriction could be overcome)
62
+ * 1.2 No recursive including is supported (i.e. includes in included XSD are ignored)
63
+ * 2. Namespace support
64
+ * 2.1 Namespaces are not taken in account by processing (references with NS)
65
+ * 3. Source code
66
+ * 3.1 Only the source code allready processed by the XML parser is rendered - implications:
67
+ * == no access to the XML head line (<?xml version="1.0" encoding="utf-8"?>)
68
+ * == "expanded" CDATA blocks (parser processes the CDATA,
69
+ * XSLT does not have access to the original code)
70
+ * == no control over the code page
71
+ * == processing of special characters
72
+ * == namespace nodes are not rendered (just the namespace aliases)
73
+ * ====================================================================
74
+ * Possible improvements:
75
+ * * Functional requirements
76
+ * + SOAP 1.2 binding (http://schemas.xmlsoap.org/wsdl/soap12/WSDL11SOAP12.pdf)
77
+ * + WSDL 2.0 (http://www.w3.org/TR/2006/CR-wsdl20-primer-20060327/)
78
+ * + Recognition of WSDL patterns (interface, binding, service instance, ...)
79
+ * - Creating an xsd-viewer.xsl for XML-Schema file viewing
80
+ * (extracting the functionality from wsdl-viewer into separate XSLT)
81
+ * - Check the full support of the WSDL and XSD going through the standards
82
+ * - Real-world WSDL testing
83
+ * - XSLT 2.0 (http://www-128.ibm.com/developerworks/library/x-xslt20pt5.html) ???
84
+ * ? Adding more derived information
85
+ * * to be defined, what non-trivial information can we read out from the WSDL
86
+ * * XSLT
87
+ * + Modularization
88
+ * - Is it meaningful?
89
+ * - Maybe more distribution alternatives (modular, fat monolithic, thin performance monolithic)?
90
+ * - Distribution build automatization
91
+ * + Dynamic page: JavaSript
92
+ * + Performance
93
+ * - Better code comments / documentation
94
+ * - SOAP client form - for testing the web service (AJAX based)
95
+ * - New XSD parser - clean-up the algorithm
96
+ * - Complete (recursive, multiple) include support
97
+ * ? Namespace-aware version (no string processing hacks ;-)
98
+ * * I think, because of the goal to support as many engines as possible,
99
+ * this requirement is unrealistic. Maybe when XSLT 2.0 will be supported
100
+ * in a huge majority of platforms, we can rethink this point....
101
+ * (problems with different functionality of namespace-uri XPath function by different engines)
102
+ * * Development architecture
103
+ * - Setup of the development infrastructure
104
+ * - Unit testing
105
+ * ? Collaboration platform
106
+ * * Documentation, web
107
+ * - Better user guide
108
+ * ? Forum, Wiki
109
+ * ====================================================================
110
+ -->
111
+
112
+
113
+ <!--
114
+ * ====================================================================
115
+ * History:
116
+ * 2005-04-15 - Initial implementation
117
+ * 2005-09-12 - Removed xsl:key to be able to use the James Clark's XT engine on W3C web-site
118
+ * 2006-10-06 - Removed the Oliver Becker's method of conditional selection
119
+ * of a value in a single expression (in Xalan/XSLTC this hack does not work!)
120
+ * 2005-10-07 - Duplicated operations
121
+ * 2006-12-08 - Import element support
122
+ * 2006-12-14 - Displays all fault elements (not just the first one)
123
+ * 2006-12-28 - W3C replaced silently the James Clark's XT engine with Michael Kay's closed-source Saxon!
124
+ * wsdl-viewer.xsl will no longer support XT engine
125
+ * 2007-02-28 - Stack-overflow bug (if the XSD element @name and @type are identic)
126
+ * 2007-03-08 - 3.0.00 - New parsing, new layout
127
+ * 2007-03-28 - 3.0.01 - Fix: New anti-recursion defense (no error message by recursion
128
+ * because of dirty solution of namespace processing)
129
+ * - Added: variables at the top to turn on/off certain details
130
+ * 2007-03-29 - 3.0.02 - Layout clean-up for IE
131
+ * 2007-03-29 - 3.0.03 - Fix: Anti-recursion algorithm
132
+ * 2007-03-30 - 3.0.04 - Added: source code rendering of imported WSDL and XSD
133
+ * 2007-04-15 - 3.0.05 - Fix: Recursive calls in element type rendering
134
+ * - Fix: Rendering of messages (did not render the message types of complex types)
135
+ * - Fix: Links in src. by arrays
136
+ * - Fix: $binding-info
137
+ * 2007-04-15 - 3.0.06 - Added: Extended rendering control ENABLE-xxx parameters
138
+ * - Changed: Anti-recursion algorithm has recursion-depth parameter
139
+ * 2007-07-19 - 3.0.07 - Fix: Rendering of array type in detail
140
+ * 2007-08-01 - 3.0.08 - Fix: xsl:template name="render-type"
141
+ * Fix: typo - "Impotred WSDL" should be "Impotred WSDL"
142
+ * 2007-08-16 - 3.0.09 - Fix: xsl:template name="render-type" - anti recursion
143
+ * 2007-12-05 - 3.1.00 - Modularized
144
+ * 2007-12-23 - 3.1.01 - Terminating message by WS without interface or service definition was removed
145
+ * (seems to be a correct state)
146
+ * 2008-08-20 - 3.1.02 - Woden-214: Anti-recursion bypassed in xsd:choice element
147
+ * 2010-08-10 HB: removed information not relevant for ONVIF and improved readiblity
148
+ * 2016-04-22 HS+HB: improve expansion ComplexType which has attribute and extension
149
+ * 2016-04-28 HS: improve recursive trace beyond namespaces
150
+ * ====================================================================
151
+ -->
152
+ <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
153
+ xmlns="http://www.w3.org/1999/xhtml"
154
+ xmlns:ws="http://schemas.xmlsoap.org/wsdl/"
155
+ xmlns:ws2="http://www.w3.org/ns/wsdl"
156
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
157
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
158
+ xmlns:local="http://tomi.vanek.sk/xml/wsdl-viewer"
159
+ xmlns:html="http://www.w3.org/1999/xhtml"
160
+ version="1.0"
161
+ exclude-result-prefixes="ws ws2 xsd soap local html">
162
+
163
+ <xsl:output method="xml" version="1.0" encoding="utf-8" indent="no"
164
+ omit-xml-declaration="no"
165
+ media-type="text/html"
166
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
167
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"/>
168
+
169
+ <xsl:strip-space elements="*"/>
170
+
171
+ <xsl:param name="wsdl-viewer.version">3.1.01</xsl:param>
172
+
173
+
174
+
175
+ <!--
176
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
177
+ Begin of included transformation: wsdl-viewer-global.xsl
178
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
179
+ -->
180
+ <xsl:param name="ENABLE-SERVICE-PARAGRAPH" select="true()"/>
181
+ <xsl:param name="ENABLE-OPERATIONS-PARAGRAPH" select="true()"/>
182
+ <xsl:param name="ENABLE-SRC-CODE-PARAGRAPH" select="false()"/>
183
+ <xsl:param name="ENABLE-ABOUT-PARAGRAPH" select="true()"/>
184
+ <xsl:param name="ENABLE-OPERATIONS-TYPE" select="true()"/>
185
+ <xsl:param name="ENABLE-LINK" select="true()"/>
186
+ <xsl:param name="ENABLE-INOUTFAULT" select="true()"/>
187
+ <xsl:param name="ENABLE-STYLEOPTYPEPATH" select="true()"/>
188
+ <xsl:param name="ENABLE-DESCRIPTION" select="true()"/>
189
+ <xsl:param name="ENABLE-PORTTYPE-NAME" select="true()"/>
190
+ <xsl:param name="ENABLE-ANTIRECURSION-PROTECTION" select="true()"/>
191
+ <xsl:param name="ANTIRECURSION-DEPTH">3</xsl:param>
192
+ <xsl:variable name="GENERATED-BY">Generated by wsdl-viewer.xsl</xsl:variable>
193
+ <xsl:variable name="PORT-TYPE-TEXT">Port type</xsl:variable>
194
+ <xsl:variable name="IFACE-TEXT">Interface</xsl:variable>
195
+ <xsl:variable name="SOURCE-CODE-TEXT">Source code</xsl:variable>
196
+ <xsl:variable name="RECURSIVE"> ... is recursive</xsl:variable>
197
+ <xsl:variable name="SRC-PREFIX">src.</xsl:variable>
198
+ <xsl:variable name="SRC-FILE-PREFIX">src.file.</xsl:variable>
199
+ <xsl:variable name="OPERATIONS-PREFIX">op.</xsl:variable>
200
+ <xsl:variable name="PORT-PREFIX">port.</xsl:variable>
201
+ <xsl:variable name="IFACE-PREFIX">iface.</xsl:variable>
202
+ <xsl:variable name="global.wsdl-names"
203
+ select="/*/*[(local-name() = 'import' or local-name() = 'include') and @location]/@location"/>
204
+ <xsl:variable name="global.wsdl-name"
205
+ select="/*/*[(local-name() = 'import' or local-name() = 'include') and @location][1]/@location"/>
206
+ <xsl:variable name="consolidated-wsdl" select="/*"/>
207
+ <xsl:variable name="extended-wsdl" select="/* | document($global.wsdl-names)/*"/>
208
+ <xsl:variable name="global.xsd-name"
209
+ select="($consolidated-wsdl/*[local-name() = 'types']//xsd:import[@schemaLocation] | $consolidated-wsdl/*[local-name() = 'types']//xsd:include[@schemaLocation])/@schemaLocation"/>
210
+ <xsl:variable name="consolidated-xsd"
211
+ select="(document($global.xsd-name)/xsd:schema/xsd:*|/*/*[local-name() = 'types']/xsd:schema/xsd:*)[local-name() = 'complexType' or local-name() = 'element' or local-name() = 'simpleType']"/>
212
+ <xsl:variable name="exclude-local-xsd"
213
+ select="(document($global.xsd-name)/xsd:schema/xsd:*)[local-name() = 'complexType' or local-name() = 'element' or local-name() = 'simpleType']"/>
214
+ <xsl:variable name="target-prefix" select="substring-before(/ws:definitions/ws:message/ws:part/@element,':')"/>
215
+ <xsl:variable name="local-types"
216
+ select="/ws:definitions/ws:types/xsd:schema/xsd:complexType|/ws:definitions/ws:types/xsd:schema/xsd:simpleType"/>
217
+ <xsl:variable name="global.service-name"
218
+ select="concat($consolidated-wsdl/ws:service/@name, $consolidated-wsdl/ws2:service/@name)"/>
219
+ <xsl:variable name="global.binding-name"
220
+ select="concat($consolidated-wsdl/ws:binding/@name, $consolidated-wsdl/ws2:binding/@name)"/>
221
+ <xsl:variable name="html-title">
222
+ <xsl:apply-templates select="/*" mode="html-title.render"/>
223
+ </xsl:variable>
224
+
225
+ <!--
226
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
227
+ End of included transformation: wsdl-viewer-global.xsl
228
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
229
+ -->
230
+
231
+
232
+
233
+ <!--
234
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
235
+ Begin of included transformation: wsdl-viewer-css.xsl
236
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
237
+ -->
238
+ <xsl:variable name="css">
239
+
240
+ /**
241
+ wsdl-viewer.css
242
+ */
243
+
244
+ /**
245
+ =========================================
246
+ Body
247
+ =========================================
248
+ */
249
+ html {
250
+ background-color: #FFFFFF;
251
+ }
252
+
253
+ body {
254
+ margin: 0;
255
+ padding: 0;
256
+ height: auto;
257
+ color: white;
258
+ background-color: #FFFFFF;
259
+ font-family:Tahoma,Arial,Helvetica;
260
+ font-size:9pt;
261
+ text-decoration:none;
262
+ }
263
+
264
+ #outer_box {
265
+ padding: 3px 3px 3px 194px;
266
+ }
267
+
268
+ #inner_box {
269
+ width: auto;
270
+ background-color: white;
271
+ color: black;
272
+ border: 1px solid #0063BE;
273
+ }
274
+
275
+ /**
276
+ =========================================
277
+ Fixed box with links
278
+ =========================================
279
+ */
280
+ #outer_links {
281
+ position: fixed;
282
+ left: 0px;
283
+ top: 0px;
284
+ margin: 3px;
285
+ padding: 1px;
286
+ z-index: 200;
287
+ width: 180px;
288
+ height: auto;
289
+ background-color: gainsboro;
290
+ padding-top: 2px;
291
+ border: 1px solid #0063BE;
292
+ }
293
+
294
+ * html #outer_links /* Override above rule for IE */
295
+ {
296
+ position: absolute;
297
+ width: 188px;
298
+ top: expression(offsetParent.scrollTop + 0);
299
+ }
300
+
301
+ #links {
302
+ margin: 1px;
303
+ padding: 3px;
304
+ background-color: white;
305
+ height: 350px;
306
+ overflow: auto;
307
+ border: 1px solid #0063BE;
308
+ }
309
+
310
+ #links ul {
311
+ left: -999em;
312
+ list-style: none;
313
+ margin: 0;
314
+ padding: 0;
315
+ z-index: 100;
316
+ }
317
+
318
+ #links li {
319
+ margin: 0;
320
+ padding: 2px 4px;
321
+ width: auto;
322
+ z-index: 100;
323
+ }
324
+
325
+ #links ul li {
326
+ margin: 0;
327
+ padding: 2px 4px;
328
+ width: auto;
329
+ z-index: 100;
330
+ }
331
+
332
+ #links a {
333
+ display: block;
334
+ padding: 0 2px;
335
+ color: #42B4E6;
336
+ width: auto;
337
+ border: 1px solid white;
338
+ text-decoration: none;
339
+ white-space: nowrap;
340
+ }
341
+
342
+ #links a:hover {
343
+ color: white;
344
+ background-color: gray;
345
+ border: 1px solid gray;
346
+ }
347
+
348
+
349
+ /**
350
+ =========================================
351
+ Navigation tabs
352
+ =========================================
353
+ */
354
+
355
+ #outer_nav {
356
+ background-color: yellow;
357
+ padding: 0;
358
+ margin: 0;
359
+ }
360
+
361
+ #nav {
362
+ height: 100%;
363
+ width: auto;
364
+ margin: 0;
365
+ padding: 0;
366
+ background-color: gainsboro;
367
+ border-top: 1px solid gray;
368
+ border-bottom: 3px solid gray;
369
+ z-index: 100;
370
+ font: bold 90%/120% Arial, Helvetica, sans-serif;
371
+ letter-spacing: 2px;
372
+ }
373
+
374
+ #nav ul {
375
+ background-color: gainsboro;
376
+ height: auto;
377
+ width: auto;
378
+ list-style: none;
379
+ margin: 0;
380
+ padding: 0;
381
+ z-index: 100;
382
+
383
+ border: 1px solid silver;
384
+ border-top-color: black;
385
+ border-width: 1px 0 9px;
386
+ }
387
+
388
+ #nav li {
389
+ display: inline;
390
+ padding: 0;
391
+ margin: 0;
392
+ }
393
+
394
+ #nav a {
395
+ position: relative;
396
+ top: 3px;
397
+ float:left;
398
+ width:auto;
399
+ padding: 8px 10px 6px 10px;
400
+ margin: 3px 3px 0;
401
+ border: 1px solid gray;
402
+ border-width: 2px 2px 3px 2px;
403
+
404
+ color: black;
405
+ background-color: silver;
406
+ text-decoration:none;
407
+ text-transform: uppercase;
408
+ }
409
+
410
+ #nav a:hover {
411
+ margin-top: 1px;
412
+ padding-top: 9px;
413
+ padding-bottom: 7px;
414
+ color: #42B4E6;
415
+ background-color: gainsboro;
416
+ }
417
+
418
+ #nav a.current:link,
419
+ #nav a.current:visited,
420
+ #nav a.current:hover {
421
+ background: white;
422
+ color: black;
423
+ text-shadow:none;
424
+ margin-top: 0;
425
+ padding-top: 11px;
426
+ padding-bottom: 9px;
427
+ border-bottom-width: 0;
428
+ border-color: #87D300;
429
+ }
430
+
431
+ #nav a:active {
432
+ background-color: silver;
433
+ color: white;
434
+ }
435
+
436
+
437
+
438
+ /**
439
+ =========================================
440
+ Content
441
+ =========================================
442
+ */
443
+ #header {
444
+ margin: 0;
445
+ padding: .5em 4em 3.5em .5em;
446
+ color: #3F55A5;
447
+ background-color: #FFFFFF;
448
+ border: 1px solid #3F55A5;
449
+ }
450
+
451
+ #content {
452
+ margin: 0;
453
+ padding: 0 2em .5em;
454
+ }
455
+
456
+ #footer {
457
+ clear: both;
458
+ margin: 0;
459
+ padding: .5em 2em;
460
+ color: gray;
461
+ background-color: gainsboro;
462
+ font-size: 80%;
463
+ border-top: 1px dotted gray;
464
+ }
465
+
466
+ .single_column {
467
+ padding: 10px 10px 10px 10px;
468
+ /*margin: 0px 33% 0px 0px; */
469
+ margin: 3px 0;
470
+ }
471
+
472
+ #flexi_column {
473
+ padding: 10px 10px 10px 10px;
474
+ /*margin: 0px 33% 0px 0px; */
475
+ margin: 0px 212px 0px 0px;
476
+ }
477
+
478
+ #fix_column {
479
+ float: right;
480
+ padding: 10px 10px 10px 10px;
481
+ margin: 0px;
482
+ width: 205px;
483
+ /*width: 30%; */
484
+ voice-family: "\"}\"";
485
+ voice-family:inherit;
486
+ /* width: 30%; */
487
+ width: 205px;
488
+ }
489
+ html&gt;body #rightColumn {
490
+ width: 205px; /* ie5win fudge ends */
491
+ } /* Opera5.02 shows a 2px gap between. N6.01Win sometimes does.
492
+ Depends on amount of fill and window size and wind direction. */
493
+
494
+ /**
495
+ =========================================
496
+ Label / value
497
+ =========================================
498
+ */
499
+
500
+ .page {
501
+ border-bottom: 3px dotted #0063BE;
502
+ margin: 0;
503
+ padding: 10px 0 20px 0;
504
+ }
505
+
506
+ .value, .label {
507
+ margin: 0;
508
+ padding: 0;
509
+ max-width: 70em;
510
+ }
511
+
512
+ .label {
513
+ /* float: left;*/
514
+ width: 100%;
515
+ text-align: left;
516
+ font-weight: bold;
517
+ padding-bottom: .5em;
518
+ margin-right: 0;
519
+ color: #356db4;
520
+ }
521
+
522
+ .value {
523
+ color: #1E3E66;
524
+ padding-bottom: .5em;
525
+ }
526
+
527
+ strong, strong a {
528
+ color: #1E3E66;
529
+ font-weight: bold;
530
+ letter-spacing: 1px;
531
+ margin-left: 2px;
532
+ }
533
+
534
+
535
+ /**
536
+ =========================================
537
+ Links
538
+ =========================================
539
+ */
540
+
541
+ a.local:link,
542
+ a.local:visited {
543
+ color: #42B4E6;
544
+ margin-left: 10px;
545
+ border-bottom: 1px dotted #42B4E6;
546
+ text-decoration: none;
547
+ /* font-style: italic;*/
548
+ }
549
+
550
+ a.local:hover {
551
+ background-color: gainsboro;
552
+ color: #1E3E66;
553
+ padding-bottom: 1px;
554
+ border-bottom: 1px solid #1E3E66;
555
+ }
556
+
557
+ a.target:link,
558
+ a.target:visited,
559
+ a.target:hover
560
+ {
561
+ text-decoration: none;
562
+ background-color: transparent;
563
+ border-bottom-type: none;
564
+ }
565
+
566
+ /**
567
+ =========================================
568
+ Box, Shadow
569
+ =========================================
570
+ */
571
+
572
+ .box {
573
+ -moz-border-radius-bottomleft:3px;
574
+ -moz-border-radius-bottomright:3px;
575
+ -moz-border-radius-topleft:3px;
576
+ -moz-border-radius-topright:3px;
577
+ background-color:#EAEEF7;
578
+ border-bottom-color:#7994CB;
579
+ border-bottom-style:solid;
580
+ border-bottom-width:1px;
581
+ border-left-color-ltr-source:physical;
582
+ border-left-color-rtl-source:physical;
583
+ border-left-color-value:#7994CB;
584
+ border-left-style-ltr-source:physical;
585
+ border-left-style-rtl-source:physical;
586
+ border-left-style-value:solid;
587
+ border-left-width-ltr-source:physical;
588
+ border-left-width-rtl-source:physical;
589
+ border-left-width-value:1px;
590
+ border-right-color-ltr-source:physical;
591
+ border-right-color-rtl-source:physical;
592
+ border-right-color-value:#7994CB;
593
+ border-right-style-ltr-source:physical;
594
+ border-right-style-rtl-source:physical;
595
+ border-right-style-value:solid;
596
+ border-right-width-ltr-source:physical;
597
+ border-right-width-rtl-source:physical;
598
+ border-right-width-value:1px;
599
+ border-top-color:#7994CB;
600
+ border-top-style:solid;
601
+ border-top-width:1px;
602
+ padding-left:6px;
603
+ padding-right:4px;
604
+ padding-top:6px;
605
+ max-width: 70em;
606
+ }
607
+
608
+ .shadow {
609
+ background: silver;
610
+ position: relative;
611
+ top: 5px;
612
+ left: 4px;
613
+ }
614
+
615
+ .shadow div {
616
+ position: relative;
617
+ top: -5px;
618
+ left: -4px;
619
+ }
620
+
621
+ /**
622
+ =========================================
623
+ Floatcontainer
624
+ =========================================
625
+ */
626
+
627
+ .spacer
628
+ {
629
+ display: block;
630
+ height: 0;
631
+ font-size: 0;
632
+ line-height: 0;
633
+ margin: 0;
634
+ padding: 0;
635
+ border-style: none;
636
+ clear: both;
637
+ visibility:hidden;
638
+ }
639
+
640
+ .floatcontainer:after {
641
+ content: ".";
642
+ display: block;
643
+ height: 0;
644
+ font-size:0;
645
+ clear: both;
646
+ visibility:hidden;
647
+ }
648
+ .floatcontainer{
649
+ display: inline-table;
650
+ } /* Mark Hadley's fix for IE Mac */ /* Hides from IE Mac \*/ *
651
+ html .floatcontainer {
652
+ height: 1%;
653
+ }
654
+ .floatcontainer{
655
+ display:block;
656
+ } /* End Hack
657
+ */
658
+
659
+ /**
660
+ =========================================
661
+ Source code
662
+ =========================================
663
+ */
664
+
665
+ .indent {
666
+ margin: 2px 0 2px 20px;
667
+ }
668
+
669
+ .xml-element, .xml-proc, .xml-comment {
670
+ margin: 2px 0;
671
+ padding: 2px 0 2px 0;
672
+ }
673
+
674
+ .xml-element {
675
+ word-spacing: 3px;
676
+ color: #1E3E66;
677
+ font-weight: bold;
678
+ font-style:normal;
679
+ border-left: 1px dotted silver;
680
+ }
681
+
682
+ .xml-element div {
683
+ margin: 2px 0 2px 40px;
684
+ }
685
+
686
+ .xml-att {
687
+ color: #447FC9;
688
+ font-weight: bold;
689
+ }
690
+
691
+ .xml-att-val {
692
+ color: #447FC9;
693
+ font-weight: normal;
694
+ }
695
+
696
+ .xml-proc {
697
+ color: #3F55A5;
698
+ font-weight: normal;
699
+ /* font-style: italic;*/
700
+ }
701
+
702
+ .xml-comment {
703
+ /*color: #3F55A5;*/
704
+ color: #008000;
705
+ font-weight: normal;
706
+ /* font-style: italic;*/
707
+ }
708
+
709
+ .xml-text {
710
+ color: #3F55A5;
711
+ font-weight: normal;
712
+ font-style: normal;
713
+ }
714
+
715
+
716
+ /**
717
+ =========================================
718
+ Heading
719
+ =========================================
720
+ */
721
+ h1, h2, h3 {
722
+ margin: 10px 10px 2px;
723
+ font-family: Georgia, Times New Roman, Times, Serif;
724
+ font-weight: normal;
725
+ }
726
+
727
+ h1 {
728
+ font-weight: bold;
729
+ letter-spacing: 3px;
730
+ font-size: 220%;
731
+ line-height: 100%;
732
+ }
733
+
734
+ h2 {
735
+ font-weight: bold;
736
+ font-size: 175%;
737
+ line-height: 200%;
738
+ }
739
+
740
+ h3 {
741
+ font-size: 175%;
742
+ line-height: 175%;
743
+ /* font-style: italic; */
744
+ }
745
+
746
+ /**
747
+ =========================================
748
+ Content formatting
749
+ =========================================
750
+ */
751
+ .port {
752
+ margin-bottom: 10px;
753
+ padding-bottom: 10px;
754
+ border-bottom: 1px dashed gray;
755
+ }
756
+
757
+ .operation {
758
+ margin-bottom: 20px;
759
+ padding-bottom: 10px;
760
+ border-bottom: 1px dashed gray;
761
+ }
762
+
763
+
764
+ /* --------------------------------------------------------
765
+ Printing
766
+ */
767
+
768
+ /*
769
+ @media print
770
+ {
771
+ #outer_links, #outer_nav {
772
+ display: none;
773
+ }
774
+ */
775
+
776
+ #outer_box {
777
+ padding: 3px;
778
+ }
779
+ /* END print media definition
780
+ }
781
+ */
782
+
783
+ </xsl:variable>
784
+
785
+ <!--
786
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
787
+ End of included transformation: wsdl-viewer-css.xsl
788
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
789
+ -->
790
+
791
+
792
+
793
+
794
+ <!--
795
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
796
+ Begin of included transformation: wsdl-viewer-util.xsl
797
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
798
+ -->
799
+ <!-- controlled HTML formatting (stripping of namespaces) -->
800
+ <xsl:template match="br">
801
+ <div style="line-height:0.3em;"><br/></div>
802
+ </xsl:template>
803
+ <xsl:template match="p">
804
+ <p>
805
+ <xsl:copy-of select="@*"/><xsl:apply-templates/>
806
+ </p>
807
+ </xsl:template>
808
+ <xsl:template match="a">
809
+ <xsl:variable name="href" select="@href"></xsl:variable>
810
+ <a href="{string($href)}"><xsl:apply-templates/></a>
811
+ </xsl:template>
812
+ <xsl:template match="ul">
813
+ <ul>
814
+ <xsl:copy-of select="@*"/><xsl:apply-templates/>
815
+ </ul>
816
+ </xsl:template>
817
+ <xsl:template match="ol">
818
+ <ol>
819
+ <xsl:copy-of select="@*"/><xsl:apply-templates/>
820
+ </ol>
821
+ </xsl:template>
822
+ <xsl:template match="li">
823
+ <li>
824
+ <xsl:copy-of select="@*"/><xsl:apply-templates/>
825
+ </li>
826
+ </xsl:template>
827
+ <xsl:template match="pre">
828
+ <pre>
829
+ <xsl:copy-of select="@*"/><xsl:apply-templates/>
830
+ </pre>
831
+ </xsl:template>
832
+
833
+ <xsl:template match="@*" mode="qname.normalized">
834
+ <xsl:variable name="local" select="substring-after(., ':')"/>
835
+ <xsl:choose>
836
+ <xsl:when test="$local">
837
+ <xsl:value-of select="$local"/>
838
+ </xsl:when>
839
+ <xsl:otherwise>
840
+ <xsl:value-of select="."/>
841
+ </xsl:otherwise>
842
+ </xsl:choose>
843
+ </xsl:template>
844
+ <xsl:template match="ws:definitions | ws2:description" mode="html-title.render">
845
+ <xsl:choose>
846
+ <xsl:when test="$global.service-name">
847
+ <xsl:value-of select="concat($global.service-name, ' - Web Service')"/>
848
+ </xsl:when>
849
+ <xsl:when test="$global.binding-name">
850
+ <xsl:value-of select="concat($global.binding-name, ' - WS Binding')"/>
851
+ </xsl:when>
852
+ <xsl:when test="ws2:interface/@name">
853
+ <xsl:value-of select="concat(ws2:interface/@name, ' - WS Interface')"/>
854
+ </xsl:when>
855
+ <xsl:otherwise>Web Service Fragment</xsl:otherwise>
856
+ <!-- <xsl:otherwise><xsl:message terminate="yes">Syntax error in element <xsl:call-template name="src.syntax-error.path"/></xsl:message>
857
+ </xsl:otherwise>
858
+ -->
859
+ </xsl:choose>
860
+ </xsl:template>
861
+ <xsl:template name="src.syntax-error">
862
+ <xsl:message terminate="yes">Syntax error by WSDL source rendering in element <xsl:call-template name="src.syntax-error.path"/>
863
+ </xsl:message>
864
+ </xsl:template>
865
+ <xsl:template name="src.syntax-error.path">
866
+ <xsl:for-each select="parent::*">
867
+ <xsl:call-template name="src.syntax-error.path"/>
868
+ </xsl:for-each>
869
+ <xsl:value-of select="concat('/', name(), '[', position(), ']')"/>
870
+ </xsl:template>
871
+ <xsl:template match="*[local-name(.) = 'documentation']" mode="documentation.render">
872
+ <xsl:if test="$ENABLE-DESCRIPTION and string-length(.) &gt; 0">
873
+ <div class="label">Description:</div>
874
+ <div class="value">
875
+ <xsl:apply-templates select="documentation"/>
876
+ </div>
877
+ </xsl:if>
878
+ </xsl:template>
879
+ <xsl:template name="render.source-code-link">
880
+ <xsl:if test="$ENABLE-SRC-CODE-PARAGRAPH and $ENABLE-LINK">
881
+ <a class="local" href="{concat('#', $SRC-PREFIX, generate-id(.))}">
882
+ <xsl:value-of select="$SOURCE-CODE-TEXT"/>
883
+ </a>
884
+ </xsl:if>
885
+ </xsl:template>
886
+ <xsl:template name="about.detail">
887
+ <xsl:param name="version"/>
888
+ <div>
889
+ This page generation is based on <big>wsdl-viewer.xsl</big>, version <xsl:value-of select="$version"/>
890
+ <br/>
891
+ Author: <a href="http://tomi.vanek.sk/">tomi vanek</a>
892
+ <br/>
893
+ Download at <a href="http://tomi.vanek.sk/xml/wsdl-viewer.xsl">http://tomi.vanek.sk/xml/wsdl-viewer.xsl</a>.<br/>
894
+ <br/>
895
+ The transformation was inspired by the article<br/>
896
+ Uche Ogbuji: <a href="http://www-106.ibm.com/developerworks/library/ws-trans/index.html">WSDL processing with XSLT</a>
897
+ <br/>
898
+ </div>
899
+ </xsl:template>
900
+ <xsl:template name="processor-info.render">
901
+ <xsl:text>
902
+ </xsl:text>
903
+ <xsl:text>This document was generated by </xsl:text>
904
+ <a href="{system-property('xsl:vendor-url')}">
905
+ <xsl:value-of select="system-property('xsl:vendor')"/>
906
+ </a>
907
+ <xsl:text> XSLT engine.
908
+ </xsl:text>
909
+
910
+ <xsl:text>The engine processed the WSDL in XSLT </xsl:text>
911
+ <xsl:value-of select="format-number(system-property('xsl:version'), '#.0')"/>
912
+ <xsl:text> compliant mode.
913
+ </xsl:text>
914
+
915
+ </xsl:template>
916
+
917
+ <!--
918
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
919
+ End of included transformation: wsdl-viewer-util.xsl
920
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
921
+ -->
922
+
923
+
924
+
925
+ <!--
926
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
927
+ Begin of included transformation: wsdl-viewer-service.xsl
928
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
929
+ -->
930
+ <xsl:template match="ws:service|ws2:service" mode="service-start">
931
+ <div class="indent">
932
+ <div class="label">Target Namespace:</div>
933
+ <div class="value">
934
+ <xsl:value-of select="$consolidated-wsdl/@targetNamespace"/>
935
+ </div>
936
+ <xsl:apply-templates select="*[local-name(.) = 'documentation']" mode="documentation.render"/>
937
+ <xsl:apply-templates select="ws:port|ws2:endpoint" mode="service"/>
938
+ </div>
939
+ </xsl:template>
940
+ <xsl:template match="ws2:endpoint" mode="service">
941
+ <xsl:variable name="binding-name">
942
+ <xsl:apply-templates select="@binding" mode="qname.normalized"/>
943
+ </xsl:variable>
944
+ <xsl:variable name="binding" select="$consolidated-wsdl/ws2:binding[@name = $binding-name]"/>
945
+
946
+ <xsl:variable name="binding-type" select="$binding/@type"/>
947
+ <xsl:variable name="binding-protocol" select="$binding/@*[local-name() = 'protocol']"/>
948
+ <xsl:variable name="protocol">
949
+ <xsl:choose>
950
+ <xsl:when test="starts-with($binding-type, 'http://schemas.xmlsoap.org/wsdl/soap')">SOAP 1.1</xsl:when>
951
+ <xsl:when test="starts-with($binding-type, 'http://www.w3.org/2005/08/wsdl/soap')">SOAP 1.2</xsl:when>
952
+ <xsl:when test="starts-with($binding-type, 'http://schemas.xmlsoap.org/wsdl/mime')">MIME</xsl:when>
953
+ <xsl:when test="starts-with($binding-type, 'http://schemas.xmlsoap.org/wsdl/http')">HTTP</xsl:when>
954
+ <xsl:otherwise>Unknown</xsl:otherwise>
955
+ </xsl:choose>
956
+
957
+ <!-- TODO: Add all bindings to transport protocols -->
958
+ <xsl:choose>
959
+ <xsl:when test="starts-with($binding-protocol, 'http://www.w3.org/2003/05/soap/bindings/HTTP')"> over HTTP</xsl:when>
960
+ <xsl:otherwise/>
961
+ </xsl:choose>
962
+ </xsl:variable>
963
+
964
+ <!-- <div class="label">Location:</div>
965
+ <div class="value">
966
+ <xsl:value-of select="@address"/>
967
+ </div>
968
+
969
+ <div class="label">Protocol:</div>
970
+ <div class="value">
971
+ <xsl:value-of select="$protocol"/>
972
+ </div>-->
973
+
974
+ <xsl:apply-templates select="$binding" mode="service"/>
975
+
976
+ <xsl:variable name="iface-name">
977
+ <xsl:apply-templates select="../@interface" mode="qname.normalized"/>
978
+ </xsl:variable>
979
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface[@name = $iface-name]" mode="service"/>
980
+
981
+ </xsl:template>
982
+ <xsl:template match="ws2:interface" mode="service">
983
+ <h3>Interface <b>
984
+ <xsl:value-of select="@name"/>
985
+ </b>
986
+ <xsl:if test="$ENABLE-LINK">
987
+ <xsl:text> </xsl:text>
988
+
989
+ <xsl:if test="$ENABLE-OPERATIONS-PARAGRAPH">
990
+ <a class="local" href="#{concat($PORT-PREFIX, generate-id(.))}">
991
+ <xsl:value-of select="$PORT-TYPE-TEXT"/>
992
+ </a>
993
+ </xsl:if>
994
+ <xsl:call-template name="render.source-code-link"/>
995
+
996
+ </xsl:if>
997
+ </h3>
998
+
999
+ <xsl:variable name="base-iface-name">
1000
+ <xsl:apply-templates select="@extends" mode="qname.normalized"/>
1001
+ </xsl:variable>
1002
+
1003
+ <xsl:if test="$base-iface-name">
1004
+ <div class="label">Extends: </div>
1005
+ <div class="value">
1006
+ <xsl:value-of select="$base-iface-name"/>
1007
+ </div>
1008
+ </xsl:if>
1009
+
1010
+ <xsl:variable name="base-iface"
1011
+ select="$consolidated-wsdl/ws2:interface[@name = $base-iface-name]"/>
1012
+
1013
+ <div class="label">Operations:</div>
1014
+ <div class="value">
1015
+ <xsl:text>
1016
+ </xsl:text>
1017
+ <ol style="line-height: 180%;">
1018
+ <xsl:apply-templates select="$base-iface/ws2:operation | ws2:operation" mode="service">
1019
+ <xsl:sort select="@name"/>
1020
+ </xsl:apply-templates>
1021
+ </ol>
1022
+ </div>
1023
+ </xsl:template>
1024
+ <xsl:template match="ws:port" mode="service">
1025
+ <xsl:variable name="binding-name">
1026
+ <xsl:apply-templates select="@binding" mode="qname.normalized"/>
1027
+ </xsl:variable>
1028
+ <xsl:variable name="binding" select="$consolidated-wsdl/ws:binding[@name = $binding-name]"/>
1029
+
1030
+ <xsl:variable name="binding-uri"
1031
+ select="namespace-uri( $binding/*[local-name() = 'binding'] )"/>
1032
+ <xsl:variable name="protocol">
1033
+ <xsl:choose>
1034
+ <xsl:when test="starts-with($binding-uri, 'http://schemas.xmlsoap.org/wsdl/soap')">SOAP</xsl:when>
1035
+ <xsl:when test="starts-with($binding-uri, 'http://schemas.xmlsoap.org/wsdl/mime')">MIME</xsl:when>
1036
+ <xsl:when test="starts-with($binding-uri, 'http://schemas.xmlsoap.org/wsdl/http')">HTTP</xsl:when>
1037
+ <xsl:otherwise>unknown</xsl:otherwise>
1038
+ </xsl:choose>
1039
+ </xsl:variable>
1040
+
1041
+ <xsl:variable name="port-type-name">
1042
+ <xsl:apply-templates select="$binding/@type" mode="qname.normalized"/>
1043
+ </xsl:variable>
1044
+
1045
+ <xsl:variable name="port-type"
1046
+ select="$consolidated-wsdl/ws:portType[@name = $port-type-name]"/>
1047
+
1048
+
1049
+ <h3>Port <b>
1050
+ <xsl:value-of select="@name"/>
1051
+ </b>
1052
+ <xsl:if test="$ENABLE-LINK">
1053
+ <xsl:text> </xsl:text>
1054
+
1055
+ <xsl:if test="$ENABLE-OPERATIONS-PARAGRAPH">
1056
+ <a class="local" href="#{concat($PORT-PREFIX, generate-id($port-type))}">
1057
+ <xsl:value-of select="$PORT-TYPE-TEXT"/>
1058
+ </a>
1059
+ </xsl:if>
1060
+ <xsl:call-template name="render.source-code-link"/>
1061
+
1062
+ </xsl:if>
1063
+ </h3>
1064
+
1065
+ <!-- <div class="label">Location:</div>
1066
+ <div class="value">
1067
+ <xsl:value-of select="*[local-name() = 'address']/@location"/>
1068
+ </div>
1069
+
1070
+ <div class="label">Protocol:</div>
1071
+ <div class="value">
1072
+ <xsl:value-of select="$protocol"/>
1073
+ </div>-->
1074
+
1075
+ <xsl:apply-templates select="$binding" mode="service"/>
1076
+
1077
+ <div class="label">Operations:</div>
1078
+ <div class="value">
1079
+ <xsl:text>
1080
+ </xsl:text>
1081
+ <ol style="line-height: 180%;">
1082
+ <xsl:apply-templates select="$consolidated-wsdl/ws:portType[@name = $port-type-name]/ws:operation"
1083
+ mode="service">
1084
+ <xsl:sort select="@name"/>
1085
+ </xsl:apply-templates>
1086
+ </ol>
1087
+ </div>
1088
+ </xsl:template>
1089
+ <xsl:template match="ws:operation|ws2:operation" mode="service">
1090
+ <li>
1091
+ <big>
1092
+ <i>
1093
+ <xsl:value-of select="@name"/>
1094
+ </i>
1095
+ </big>
1096
+ <xsl:if test="$ENABLE-LINK">
1097
+ <xsl:if test="$ENABLE-OPERATIONS-PARAGRAPH">
1098
+ <a class="local" href="{concat('#', $OPERATIONS-PREFIX, generate-id(.))}">Detail</a>
1099
+ </xsl:if>
1100
+ <xsl:call-template name="render.source-code-link"/>
1101
+ </xsl:if>
1102
+ </li>
1103
+ </xsl:template>
1104
+ <xsl:template match="ws:binding|ws2:binding" mode="service">
1105
+ <xsl:variable name="real-binding" select="*[local-name() = 'binding']|self::ws2:*"/>
1106
+
1107
+ <xsl:if test="$real-binding/@style">
1108
+ <div class="label">Default style:</div>
1109
+ <div class="value">
1110
+ <xsl:value-of select="$real-binding/@style"/>
1111
+ </div>
1112
+ </xsl:if>
1113
+
1114
+
1115
+ <xsl:if test="$real-binding/@transport|$real-binding/*[local-name() = 'protocol']">
1116
+ <xsl:variable name="protocol"
1117
+ select="concat($real-binding/@transport, $real-binding/*[local-name() = 'protocol'])"/>
1118
+ <div class="label">Transport protocol:</div>
1119
+ <div class="value">
1120
+ <xsl:choose>
1121
+ <xsl:when test="$protocol = 'http://schemas.xmlsoap.org/soap/http'">SOAP over HTTP</xsl:when>
1122
+ <xsl:otherwise>
1123
+ <xsl:value-of select="$protocol"/>
1124
+ </xsl:otherwise>
1125
+ </xsl:choose>
1126
+ </div>
1127
+ </xsl:if>
1128
+
1129
+ <xsl:if test="$real-binding/@verb">
1130
+ <div class="label">Default method:</div>
1131
+ <div class="value">
1132
+ <xsl:value-of select="$real-binding/@verb"/>
1133
+ </div>
1134
+ </xsl:if>
1135
+ </xsl:template>
1136
+
1137
+ <!--
1138
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1139
+ End of included transformation: wsdl-viewer-service.xsl
1140
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1141
+ -->
1142
+
1143
+
1144
+
1145
+ <!--
1146
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1147
+ Begin of included transformation: wsdl-viewer-operations.xsl
1148
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1149
+ -->
1150
+ <xsl:template match="ws2:interface" mode="operations">
1151
+ <xsl:if test="$ENABLE-PORTTYPE-NAME">
1152
+ <h3>
1153
+ <a name="{concat($IFACE-PREFIX, generate-id(.))}">
1154
+ <xsl:value-of select="$IFACE-TEXT"/>
1155
+ <xsl:text>
1156
+ </xsl:text>
1157
+ <b>
1158
+ <xsl:value-of select="@name"/>
1159
+ </b>
1160
+ </a>
1161
+ <xsl:call-template name="render.source-code-link"/>
1162
+ </h3>
1163
+ </xsl:if>
1164
+
1165
+ <ol>
1166
+ <xsl:apply-templates select="ws2:operation" mode="operations">
1167
+ <xsl:sort select="@name"/>
1168
+ </xsl:apply-templates>
1169
+ </ol>
1170
+ </xsl:template>
1171
+ <xsl:template match="ws2:operation" mode="operations">
1172
+ <xsl:variable name="binding-info"
1173
+ select="$consolidated-wsdl/ws2:binding[@interface = current()/../@name or substring-after(@interface, ':') = current()/../@name]/ws2:operation[@ref = current()/@name or substring-after(@ref, ':') = current()/@name]"/>
1174
+ <li>
1175
+ <xsl:if test="position() != last()">
1176
+ <xsl:attribute name="class">operation</xsl:attribute>
1177
+ </xsl:if>
1178
+ <big>
1179
+ <b>
1180
+ <a name="{concat($OPERATIONS-PREFIX, generate-id(.))}">
1181
+ <xsl:value-of select="@name"/>
1182
+ </a>
1183
+ </b>
1184
+ </big>
1185
+ <div class="value">
1186
+ <xsl:text>
1187
+ </xsl:text>
1188
+ <xsl:call-template name="render.source-code-link"/>
1189
+ </div>
1190
+ <xsl:apply-templates select="ws2:documentation" mode="documentation.render"/>
1191
+
1192
+ <xsl:if test="$ENABLE-STYLEOPTYPEPATH">
1193
+ <!-- TODO: add the operation attributes - according the WSDL 2.0 spec. -->
1194
+ </xsl:if>
1195
+ <xsl:apply-templates select="ws2:input|ws2:output|../ws2:fault[@name = ws2:infault/@ref or @name = ws2:outfault/@ref]"
1196
+ mode="operations.message">
1197
+ <xsl:with-param name="binding-data" select="$binding-info"/>
1198
+ </xsl:apply-templates>
1199
+ </li>
1200
+ </xsl:template>
1201
+ <xsl:template match="ws2:input|ws2:output|ws2:fault" mode="operations.message">
1202
+ <xsl:param name="binding-data"/>
1203
+ <xsl:if test="$ENABLE-INOUTFAULT">
1204
+ <div class="label">
1205
+ <xsl:value-of select="concat(translate(substring(local-name(.), 1, 1), 'abcdefghijklmnoprstuvwxyz', 'ABCDEFGHIJKLMNOPRSTUVWXYZ'), substring(local-name(.), 2), ':')"/>
1206
+ </div>
1207
+
1208
+ <div class="value">
1209
+ <xsl:variable name="type-name">
1210
+ <xsl:apply-templates select="@element" mode="qname.normalized"/>
1211
+ </xsl:variable>
1212
+
1213
+ <xsl:call-template name="render-type">
1214
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1215
+ </xsl:call-template>
1216
+
1217
+ <xsl:call-template name="render.source-code-link"/>
1218
+
1219
+ <xsl:variable name="type-tree"
1220
+ select="$consolidated-xsd[@name = $type-name and not(xsd:simpleType)][1]"/>
1221
+ <xsl:apply-templates select="$type-tree" mode="operations.message.part"/>
1222
+ </div>
1223
+ </xsl:if>
1224
+ </xsl:template>
1225
+ <xsl:template match="ws:portType" mode="operations">
1226
+ <div>
1227
+ <xsl:if test="position() != last()">
1228
+ <xsl:attribute name="class">port</xsl:attribute>
1229
+ </xsl:if>
1230
+ <xsl:if test="$ENABLE-PORTTYPE-NAME">
1231
+ <h3>
1232
+ <a name="{concat($PORT-PREFIX, generate-id(.))}">
1233
+ <xsl:value-of select="$PORT-TYPE-TEXT"/>
1234
+ <xsl:text>
1235
+ </xsl:text>
1236
+ <b>
1237
+ <xsl:value-of select="@name"/>
1238
+ </b>
1239
+ </a>
1240
+ <xsl:call-template name="render.source-code-link"/>
1241
+ </h3>
1242
+ </xsl:if>
1243
+ <ol>
1244
+ <xsl:apply-templates select="ws:operation" mode="operations">
1245
+ <xsl:sort select="@name"/>
1246
+ </xsl:apply-templates>
1247
+ </ol>
1248
+ </div>
1249
+ </xsl:template>
1250
+ <xsl:template match="ws:operation" mode="operations">
1251
+ <xsl:variable name="binding-info"
1252
+ select="$consolidated-wsdl/ws:binding[@type = current()/../@name or substring-after(@type, ':') = current()/../@name]/ws:operation[@name = current()/@name]"/>
1253
+ <li>
1254
+ <xsl:if test="position() != last()">
1255
+ <xsl:attribute name="class">operation</xsl:attribute>
1256
+ </xsl:if>
1257
+ <big>
1258
+ <b>
1259
+ <a name="{concat($OPERATIONS-PREFIX, string(@name))}">
1260
+ <xsl:value-of select="@name"/>
1261
+ </a>
1262
+ </b>
1263
+ </big>
1264
+ <div class="value">
1265
+ <xsl:text>
1266
+ </xsl:text>
1267
+ <xsl:call-template name="render.source-code-link"/>
1268
+ </div>
1269
+
1270
+ <xsl:if test="$ENABLE-DESCRIPTION and string-length(ws:documentation) &gt; 0">
1271
+ <div class="label">Description:</div>
1272
+ <div class="value">
1273
+ <xsl:apply-templates select="ws:documentation" />
1274
+ </div>
1275
+ </xsl:if>
1276
+
1277
+ <xsl:if test="$ENABLE-STYLEOPTYPEPATH">
1278
+ <xsl:variable name="binding-operation" select="$binding-info/*[local-name() = 'operation']"/>
1279
+ <xsl:if test="$binding-operation/@style">
1280
+ <div class="label">Style:</div>
1281
+ <div class="value">
1282
+ <xsl:value-of select="$binding-operation/@style"/>
1283
+ </div>
1284
+ </xsl:if>
1285
+ <!-- HB: suppress optionat type
1286
+ <div class="label">Operation type:</div>
1287
+ <div class="value">
1288
+ <xsl:choose>
1289
+ <xsl:when test="$binding-info/ws:input[not(../ws:output)]">
1290
+ <i>One-way.</i> The endpoint receives a message.</xsl:when>
1291
+ <xsl:when test="$binding-info/ws:input[following-sibling::ws:output]">
1292
+ <i>Request-response.</i> The endpoint receives a message, and sends a correlated message.</xsl:when>
1293
+ <xsl:when test="$binding-info/ws:input[preceding-sibling::ws:output]">
1294
+ <i>Solicit-response.</i> The endpoint sends a message, and receives a correlated message.</xsl:when>
1295
+ <xsl:when test="$binding-info/ws:output[not(../ws:input)]">
1296
+ <i>Notification.</i> The endpoint sends a message.</xsl:when>
1297
+ <xsl:otherwise>unknown</xsl:otherwise>
1298
+ </xsl:choose>
1299
+ </div>
1300
+ -->
1301
+ <xsl:if test="string-length($binding-operation/@soapAction) &gt; 0">
1302
+ <div class="label">SOAP action:</div>
1303
+ <div class="value">
1304
+ <xsl:value-of select="$binding-operation/@soapAction"/>
1305
+ </div>
1306
+ </xsl:if>
1307
+
1308
+ <xsl:if test="$binding-operation/@location">
1309
+ <div class="label">HTTP path:</div>
1310
+ <div class="value">
1311
+ <xsl:value-of select="$binding-operation/@location"/>
1312
+ </div>
1313
+ </xsl:if>
1314
+ </xsl:if>
1315
+ <xsl:apply-templates select="ws:input|ws:output|ws:fault" mode="operations.message">
1316
+ <xsl:with-param name="binding-data" select="$binding-info"/>
1317
+ </xsl:apply-templates>
1318
+ </li>
1319
+ </xsl:template>
1320
+ <xsl:template match="ws:input|ws:output|ws:fault" mode="operations.message">
1321
+ <xsl:param name="binding-data"/>
1322
+ <xsl:if test="$ENABLE-INOUTFAULT">
1323
+ <div class="label">
1324
+ <xsl:value-of select="concat(translate(substring(local-name(.), 1, 1), 'abcdefghijklmnoprstuvwxyz', 'ABCDEFGHIJKLMNOPRSTUVWXYZ'), substring(local-name(.), 2), ':')"/>
1325
+ </div>
1326
+ <xsl:variable name="msg-name" select="substring-after(@message, ':')"/>
1327
+ <xsl:variable name="msg" select="$consolidated-wsdl/ws:message[@name = $msg-name]"/>
1328
+ <xsl:value-of select="$consolidated-wsdl/ws:message[@name = $msg-name]"/>
1329
+ <xsl:choose>
1330
+ <xsl:when test="$msg">
1331
+ <xsl:apply-templates select="$msg[1]" mode="operations.message">
1332
+ <xsl:with-param name="binding-data"
1333
+ select="$binding-data/ws:*[local-name(.) = local-name(current())]/*"/>
1334
+ </xsl:apply-templates>
1335
+ </xsl:when>
1336
+ <xsl:otherwise>
1337
+ <div class="value box" style="margin: 3px">
1338
+ [<xsl:value-of select="$msg-name"/>]
1339
+ </div>
1340
+ </xsl:otherwise>
1341
+ </xsl:choose>
1342
+ </xsl:if>
1343
+ </xsl:template>
1344
+ <xsl:template match="ws:message" mode="operations.message">
1345
+ <xsl:param name="binding-data"/>
1346
+ <!-- HB: suppress binding
1347
+ <div class="value">
1348
+ <xsl:value-of select="@name"/>
1349
+ <xsl:if test="$binding-data">
1350
+ <xsl:text> (</xsl:text>
1351
+ <xsl:value-of select="name($binding-data)"/>
1352
+ <xsl:variable name="use" select="$binding-data/@use"/>
1353
+ <xsl:if test="$use">
1354
+ <xsl:text>, use = </xsl:text>
1355
+ <xsl:value-of select="$use"/>
1356
+ </xsl:if>
1357
+ <xsl:variable name="part" select="$binding-data/@part"/>
1358
+ <xsl:if test="$part">
1359
+ <xsl:text>, part = </xsl:text>
1360
+ <xsl:value-of select="$part"/>
1361
+ </xsl:if>
1362
+ <xsl:text>)</xsl:text>
1363
+ </xsl:if>
1364
+ <xsl:call-template name="render.source-code-link"/>
1365
+ </div>
1366
+ -->
1367
+ <xsl:apply-templates select="ws:part" mode="operations.message"/>
1368
+ </xsl:template>
1369
+ <xsl:template match="ws:part" mode="operations.message">
1370
+ <div class="value box" style="margin: 3px">
1371
+
1372
+ <xsl:variable name="type-name" select="substring-after(@element, ':')"/>
1373
+ <xsl:call-template name="render-type">
1374
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1375
+ </xsl:call-template>
1376
+ <xsl:choose>
1377
+ <xsl:when test="$consolidated-xsd[@name = $type-name and (xsd:element)][1]">
1378
+ <xsl:variable name="part-type"
1379
+ select="$consolidated-xsd[@name = $type-name and (xsd:element)][1]"/>
1380
+ <xsl:apply-templates select="$part-type" mode="operations.message.part"/>
1381
+ </xsl:when>
1382
+ <xsl:otherwise>
1383
+ <!-- Lookup type in imported wsdl -->
1384
+ <xsl:variable name="part-type"
1385
+ select="$extended-wsdl/ws:types/*/*[@name = $type-name and not(xsd:simpleType)][1]"/>
1386
+ <xsl:apply-templates select="$part-type" mode="operations.message.part"/>
1387
+ </xsl:otherwise>
1388
+ </xsl:choose>
1389
+ </div>
1390
+ </xsl:template>
1391
+
1392
+ <!--
1393
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1394
+ End of included transformation: wsdl-viewer-operations.xsl
1395
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1396
+ -->
1397
+
1398
+
1399
+
1400
+ <!--
1401
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1402
+ Begin of included transformation: wsdl-viewer-xsd-tree.xsl
1403
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1404
+ -->
1405
+ <xsl:template match="xsd:simpleType" mode="operations.message.part">
1406
+ <xsl:if test="xsd:restriction/xsd:enumeration">
1407
+ <xsl:choose>
1408
+ <xsl:when test=" xsd:annotation">
1409
+ <div style="margin-left: 1em;">
1410
+ <xsl:apply-templates select="xsd:restriction/xsd:enumeration" mode="operations.message.part"/>
1411
+ </div>
1412
+ </xsl:when>
1413
+ <xsl:otherwise>
1414
+ <xsl:apply-templates select="xsd:restriction/xsd:enumeration" mode="render-type"/>
1415
+ </xsl:otherwise>
1416
+ </xsl:choose>
1417
+ </xsl:if>
1418
+ </xsl:template>
1419
+
1420
+ <xsl:template match="xsd:enumeration" mode="operations.message.part">
1421
+ - <xsl:value-of select="@value"/>:
1422
+ <xsl:text xml:space="preserve"> </xsl:text>
1423
+ <xsl:apply-templates select="*"/>
1424
+ <br/>
1425
+ </xsl:template>
1426
+
1427
+ <xsl:template name="recursion.should.continue">
1428
+ <xsl:param name="anti.recursion"/>
1429
+ <xsl:param name="recursion.label"/>
1430
+ <xsl:param name="recursion.count">1</xsl:param>
1431
+ <xsl:variable name="has.recursion" select="contains($anti.recursion, $recursion.label)"/>
1432
+ <xsl:variable name="anti.recursion.fragment"
1433
+ select="substring-after($anti.recursion, $recursion.label)"/>
1434
+ <xsl:choose>
1435
+ <xsl:when test="$recursion.count &gt; $ANTIRECURSION-DEPTH"/>
1436
+
1437
+ <xsl:when test="not($ENABLE-ANTIRECURSION-PROTECTION) or string-length($anti.recursion) = 0 or not($has.recursion)">
1438
+ <xsl:text>1</xsl:text>
1439
+ </xsl:when>
1440
+
1441
+ <xsl:otherwise>
1442
+ <xsl:call-template name="recursion.should.continue">
1443
+ <xsl:with-param name="anti.recursion" select="$anti.recursion.fragment"/>
1444
+ <xsl:with-param name="recursion.label" select="$recursion.label"/>
1445
+ <xsl:with-param name="recursion.count" select="$recursion.count + 1"/>
1446
+ </xsl:call-template>
1447
+ </xsl:otherwise>
1448
+ </xsl:choose>
1449
+ </xsl:template>
1450
+ <xsl:template match="xsd:complexType" mode="operations.message.part">
1451
+ <xsl:param name="anti.recursion"/>
1452
+ <xsl:call-template name="render-type"></xsl:call-template>
1453
+ <xsl:variable name="recursion.label" select="concat('[', @name, ']')"/>
1454
+ <xsl:variable name="recursion.test">
1455
+ <xsl:call-template name="recursion.should.continue">
1456
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1457
+ <xsl:with-param name="recursion.label" select="$recursion.label"/>
1458
+ </xsl:call-template>
1459
+ </xsl:variable>
1460
+
1461
+ <xsl:if test="xsd:attribute">
1462
+ <ul type="circle">
1463
+ <xsl:apply-templates select="xsd:attribute" mode="operations.message.part"/>
1464
+ </ul>
1465
+ </xsl:if>
1466
+
1467
+ <xsl:choose>
1468
+ <xsl:when test="string-length($recursion.test) != 0">
1469
+ <xsl:apply-templates select="xsd:extension | xsd:sequence | xsd:complexContent | xsd:choice" mode="operations.message.part"> <!-- HB: suppress type documentation -->
1470
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1471
+ </xsl:apply-templates>
1472
+ </xsl:when>
1473
+ <xsl:otherwise>
1474
+ <xsl:value-of select="$RECURSIVE"/>
1475
+ </xsl:otherwise>
1476
+ </xsl:choose>
1477
+
1478
+ </xsl:template>
1479
+ <xsl:template match="xsd:complexContent" mode="operations.message.part">
1480
+ <xsl:param name="anti.recursion"/>
1481
+
1482
+ <xsl:apply-templates select="*" mode="operations.message.part">
1483
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1484
+ </xsl:apply-templates>
1485
+ </xsl:template>
1486
+ <xsl:template match="xsd:restriction | xsd:extension" mode="operations.message.part">
1487
+ <xsl:param name="anti.recursion"/>
1488
+ <xsl:variable name="type-local-name" select="substring-after(@base, ':')"/>
1489
+ <xsl:variable name="type-name">
1490
+ <xsl:choose>
1491
+ <xsl:when test="$type-local-name">
1492
+ <xsl:value-of select="$type-local-name"/>
1493
+ </xsl:when>
1494
+ <xsl:when test="@base">
1495
+ <xsl:value-of select="@base"/>
1496
+ </xsl:when>
1497
+ <xsl:otherwise>unknown type</xsl:otherwise>
1498
+ </xsl:choose>
1499
+ </xsl:variable>
1500
+ <xsl:variable name="base-type" select="$consolidated-xsd[@name = $type-name][1]"/>
1501
+ <xsl:if test="$base-type != 'Array'">
1502
+ <xsl:apply-templates select="$base-type" mode="operations.message.part">
1503
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1504
+ </xsl:apply-templates>
1505
+ </xsl:if>
1506
+ <xsl:if test="xsd:attribute">
1507
+ <ul type="circle">
1508
+ <xsl:apply-templates select="xsd:attribute" mode="operations.message.part"/>
1509
+ <xsl:text xml:space="preserve"> </xsl:text> <!-- trick to avoid empty <ul/> sections -->
1510
+ </ul>
1511
+ </xsl:if>
1512
+ <xsl:apply-templates select="xsd:sequence" mode="operations.message.part">
1513
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1514
+ </xsl:apply-templates>
1515
+ </xsl:template>
1516
+ <xsl:template match="xsd:union" mode="operations.message.part">
1517
+ <xsl:call-template name="process-union">
1518
+ <xsl:with-param name="set" select="@memberTypes"/>
1519
+ </xsl:call-template>
1520
+ </xsl:template>
1521
+ <xsl:template name="process-union">
1522
+ <xsl:param name="set"/>
1523
+ <xsl:if test="$set">
1524
+ <xsl:variable name="item" select="substring-before($set, ' ')"/>
1525
+ <xsl:variable name="the-rest" select="substring-after($set, ' ')"/>
1526
+
1527
+ <xsl:variable name="type-local-name" select="substring-after($item, ':')"/>
1528
+ <xsl:variable name="type-name">
1529
+ <xsl:choose>
1530
+ <xsl:when test="$type-local-name">
1531
+ <xsl:value-of select="$type-local-name"/>
1532
+ </xsl:when>
1533
+ <xsl:otherwise>
1534
+ <xsl:value-of select="$item"/>
1535
+ </xsl:otherwise>
1536
+ </xsl:choose>
1537
+ </xsl:variable>
1538
+
1539
+ <xsl:call-template name="render-type">
1540
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1541
+ </xsl:call-template>
1542
+
1543
+ <xsl:call-template name="process-union">
1544
+ <xsl:with-param name="set" select="$the-rest"/>
1545
+ </xsl:call-template>
1546
+ </xsl:if>
1547
+ </xsl:template>
1548
+ <xsl:template match="xsd:sequence" mode="operations.message.part">
1549
+ <xsl:param name="anti.recursion"/>
1550
+ <ul type="square" style='margin-top:2px'>
1551
+ <xsl:apply-templates select="xsd:element|xsd:complextType" mode="operations.message.part">
1552
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1553
+ </xsl:apply-templates>
1554
+ <xsl:text xml:space="preserve"> </xsl:text> <!-- trick to avoid empty <ul/> sections -->
1555
+ </ul>
1556
+ </xsl:template>
1557
+ <xsl:template match="xsd:all|xsd:any|xsd:choice" mode="operations.message.part">
1558
+ <xsl:param name="anti.recursion"/>
1559
+
1560
+ <xsl:choose>
1561
+ <xsl:when test="self::xsd:all">
1562
+ <xsl:element name="ul">
1563
+ <xsl:attribute name="style">disc</xsl:attribute>
1564
+ <xsl:element name="li">xsd:all
1565
+ <xsl:apply-templates select="*" mode="operations.message.part">
1566
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1567
+ </xsl:apply-templates>
1568
+ </xsl:element>
1569
+ </xsl:element>
1570
+ </xsl:when>
1571
+ <xsl:when test="self::xsd:any">
1572
+ <xsl:if test="xsd:annotation">
1573
+ <xsl:element name="li">xsd:any
1574
+ <xsl:apply-templates select="*" mode="operations.message.part">
1575
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1576
+ </xsl:apply-templates>
1577
+ </xsl:element>
1578
+ </xsl:if>
1579
+ </xsl:when>
1580
+ <xsl:otherwise>
1581
+ <xsl:text>[Choice]</xsl:text>
1582
+ <xsl:element name="ul">
1583
+ <xsl:apply-templates select="*" mode="operations.message.part">
1584
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1585
+ </xsl:apply-templates>
1586
+ </xsl:element>
1587
+ </xsl:otherwise>
1588
+ </xsl:choose>
1589
+ </xsl:template>
1590
+ <xsl:template match="xsd:element[parent::xsd:schema]" mode="operations.message.part">
1591
+ <xsl:param name="anti.recursion"/>
1592
+ <xsl:variable name="recursion.label" select="concat('[', @name, ']')"/>
1593
+ <xsl:variable name="recursion.test">
1594
+ <xsl:call-template name="recursion.should.continue">
1595
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1596
+ <xsl:with-param name="recursion.label" select="$recursion.label"/>
1597
+ </xsl:call-template>
1598
+ </xsl:variable>
1599
+
1600
+ <xsl:choose>
1601
+ <xsl:when test="string-length($recursion.test) != 0">
1602
+ <xsl:variable name="type-name">
1603
+ <xsl:call-template name="xsd.element-type"/>
1604
+ </xsl:variable>
1605
+ <xsl:variable name="elem-type"
1606
+ select="$consolidated-xsd[generate-id() != generate-id(current()) and $type-name and @name=$type-name and contains(local-name(), 'Type')][1]"/>
1607
+
1608
+ <xsl:if test="$type-name != @name">
1609
+ <xsl:apply-templates select="$elem-type" mode="operations.message.part">
1610
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1611
+ </xsl:apply-templates>
1612
+
1613
+ <xsl:if test="not($elem-type)">
1614
+ <xsl:call-template name="render-type">
1615
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1616
+ </xsl:call-template>
1617
+ </xsl:if>
1618
+
1619
+ <xsl:apply-templates select="*" mode="operations.message.part">
1620
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1621
+ </xsl:apply-templates>
1622
+ </xsl:if>
1623
+ </xsl:when>
1624
+ <xsl:otherwise>
1625
+ <xsl:value-of select="$RECURSIVE"/>
1626
+ </xsl:otherwise>
1627
+ </xsl:choose>
1628
+
1629
+ </xsl:template>
1630
+ <xsl:template match="xsd:element | xsd:attribute" mode="operations.message.part">
1631
+ <xsl:param name="anti.recursion"/>
1632
+
1633
+ <xsl:variable name="recursion.label" select="concat('[', @name, ']')"/>
1634
+
1635
+ <li><b>
1636
+ <xsl:variable name="local-ref" select="concat(@name, substring-after(@ref, ':'))"/>
1637
+ <xsl:variable name="elem-name">
1638
+ <xsl:choose>
1639
+ <xsl:when test="@name">
1640
+ <xsl:value-of select="@name"/>
1641
+ </xsl:when>
1642
+ <xsl:when test="$local-ref">
1643
+ <xsl:value-of select="$local-ref"/>
1644
+ </xsl:when>
1645
+ <xsl:when test="@ref">
1646
+ <xsl:value-of select="@ref"/>
1647
+ </xsl:when>
1648
+ <xsl:otherwise>anonymous</xsl:otherwise>
1649
+ </xsl:choose>
1650
+ </xsl:variable>
1651
+ <xsl:value-of select="$elem-name"/>
1652
+ </b>
1653
+ <xsl:variable name="type-name">
1654
+ <xsl:call-template name="xsd.element-type"/>
1655
+ </xsl:variable>
1656
+
1657
+ <xsl:call-template name="render-type">
1658
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1659
+ </xsl:call-template>
1660
+
1661
+ <!-- ensure that documentation is written before type content -->
1662
+ <xsl:apply-templates select="xsd:annotation/xsd:documentation" mode="operations.message.part"/>
1663
+
1664
+ <xsl:variable name="prefix" select="substring-before(@type, ':')"/>
1665
+
1666
+ <!-- Check whether type name prefix is local -->
1667
+ <xsl:variable name="elem-type"
1668
+ select="($local-types[@name=$type-name and $prefix=$target-prefix] | $exclude-local-xsd[@name = $type-name and contains(local-name(), 'Type') and $target-prefix!=$prefix])[1]"/>
1669
+ <xsl:apply-templates select="$elem-type | *[not(xsd:documentation)]" mode="operations.message.part">
1670
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1671
+ </xsl:apply-templates>
1672
+ </li>
1673
+ </xsl:template>
1674
+ <xsl:template match="xsd:attribute[ @*[local-name() = 'arrayType'] ]"
1675
+ mode="operations.message.part">
1676
+ <xsl:param name="anti.recursion"/>
1677
+ <xsl:variable name="array-local-name"
1678
+ select="substring-after(@*[local-name() = 'arrayType'], ':')"/>
1679
+ <xsl:variable name="type-local-name" select="substring-before($array-local-name, '[')"/>
1680
+ <xsl:variable name="array-type" select="$consolidated-xsd[@name = $type-local-name][1]"/>
1681
+
1682
+ <xsl:variable name="recursion.label" select="concat('[', $type-local-name, ']')"/>
1683
+ <xsl:variable name="recursion.test">
1684
+ <xsl:call-template name="recursion.should.continue">
1685
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1686
+ <xsl:with-param name="recursion.label" select="$recursion.label"/>
1687
+ </xsl:call-template>
1688
+ </xsl:variable>
1689
+
1690
+ <xsl:choose>
1691
+ <xsl:when test="string-length($recursion.test) != 0">
1692
+ <xsl:apply-templates select="$array-type" mode="operations.message.part">
1693
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1694
+ </xsl:apply-templates>
1695
+ </xsl:when>
1696
+ <xsl:otherwise>
1697
+ <xsl:value-of select="$RECURSIVE"/>
1698
+ </xsl:otherwise>
1699
+ </xsl:choose>
1700
+ </xsl:template>
1701
+ <xsl:template name="xsd.element-type">
1702
+ <xsl:variable name="ref-or-type">
1703
+ <xsl:choose>
1704
+ <xsl:when test="@type">
1705
+ <xsl:value-of select="@type"/>
1706
+ </xsl:when>
1707
+ <xsl:otherwise>
1708
+ <xsl:value-of select="@ref"/>
1709
+ </xsl:otherwise>
1710
+ </xsl:choose>
1711
+ </xsl:variable>
1712
+
1713
+ <xsl:variable name="type-local-name" select="substring-after($ref-or-type, ':')"/>
1714
+ <xsl:variable name="type-name">
1715
+ <xsl:choose>
1716
+ <xsl:when test="$type-local-name">
1717
+ <xsl:value-of select="$type-local-name"/>
1718
+ </xsl:when>
1719
+ <xsl:when test="$ref-or-type">
1720
+ <xsl:value-of select="$ref-or-type"/>
1721
+ </xsl:when>
1722
+ <xsl:otherwise>undefined</xsl:otherwise>
1723
+ </xsl:choose>
1724
+ </xsl:variable>
1725
+ <xsl:value-of select="$type-name"/>
1726
+ </xsl:template>
1727
+ <xsl:template match="xsd:documentation" mode="operations.message.part">
1728
+ <div style="color:#1E3E66;"><xsl:apply-templates /> <!--<xsl:copy-of select="node()" />--> </div>
1729
+ </xsl:template>
1730
+ <xsl:template name="render-type">
1731
+ <xsl:param name="anti.recursion"/>
1732
+ <xsl:param name="type-local-name"/>
1733
+
1734
+ <xsl:if test="$ENABLE-OPERATIONS-TYPE">
1735
+ <xsl:variable name="properties">
1736
+ <xsl:if test="self::xsd:element | self::xsd:attribute[parent::xsd:complexType]">
1737
+ <xsl:variable name="min">
1738
+ <xsl:if test="@minOccurs = '0'">optional</xsl:if>
1739
+ </xsl:variable>
1740
+ <xsl:variable name="max">
1741
+ <xsl:if test="@maxOccurs = 'unbounded'">unbounded</xsl:if>
1742
+ </xsl:variable>
1743
+ <xsl:variable name="nillable">
1744
+ <xsl:if test="@nillable">nillable</xsl:if>
1745
+ </xsl:variable>
1746
+
1747
+ <xsl:if test="(string-length($min) + string-length($max) + string-length($nillable) + string-length(@use)) &gt; 0">
1748
+ <xsl:text> - </xsl:text>
1749
+ <xsl:value-of select="$min"/>
1750
+ <xsl:if test="string-length($min) and string-length($max)">
1751
+ <xsl:text>, </xsl:text>
1752
+ </xsl:if>
1753
+ <xsl:value-of select="$max"/>
1754
+ <xsl:if test="(string-length($min) + string-length($max)) &gt; 0 and string-length($nillable)">
1755
+ <xsl:text>, </xsl:text>
1756
+ </xsl:if>
1757
+ <xsl:value-of select="$nillable"/>
1758
+ <xsl:if test="(string-length($min) + string-length($max) + string-length($nillable)) &gt; 0 and string-length(@use)">
1759
+ <xsl:text>, </xsl:text>
1760
+ </xsl:if>
1761
+ <xsl:value-of select="@use"/>
1762
+ <xsl:text>; </xsl:text>
1763
+ </xsl:if>
1764
+ </xsl:if>
1765
+ </xsl:variable>
1766
+
1767
+ <xsl:variable name="recursion.label" select="concat('[', $type-local-name, ']')"/>
1768
+ <xsl:variable name="recursion.test">
1769
+ <xsl:call-template name="recursion.should.continue">
1770
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1771
+ <xsl:with-param name="recursion.label" select="$recursion.label"/>
1772
+ <xsl:with-param name="recursion.count" select="$ANTIRECURSION-DEPTH"/>
1773
+ </xsl:call-template>
1774
+ </xsl:variable>
1775
+
1776
+ <xsl:if test="string-length($recursion.test) != 0">
1777
+ <xsl:value-of select="$properties"/>
1778
+ <xsl:if test="string-length($type-local-name) &gt; 0">
1779
+ <xsl:call-template name="render-type.write-name">
1780
+ <xsl:with-param name="type-local-name" select="$type-local-name"/>
1781
+ </xsl:call-template>
1782
+ </xsl:if>
1783
+ <!-- HB: suppress derived types
1784
+ <xsl:choose>
1785
+ <xsl:when test="$elem-type">
1786
+
1787
+ <xsl:apply-templates select="$elem-type" mode="render-type">
1788
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1789
+ </xsl:apply-templates>
1790
+ </xsl:when>
1791
+ <xsl:otherwise>
1792
+
1793
+ <xsl:apply-templates select="*" mode="render-type">
1794
+ <xsl:with-param name="anti.recursion" select="concat($anti.recursion, $recursion.label)"/>
1795
+ </xsl:apply-templates>
1796
+ </xsl:otherwise>
1797
+ </xsl:choose>
1798
+ -->
1799
+ </xsl:if>
1800
+ </xsl:if>
1801
+ </xsl:template>
1802
+ <xsl:template name="render-type.write-name">
1803
+ <xsl:param name="type-local-name"/>
1804
+ <xsl:text> [</xsl:text>
1805
+ <!-- HB: type-style -->
1806
+ <xsl:choose>
1807
+ <xsl:when test="$type-local-name">
1808
+ <xsl:value-of select="$type-local-name"/>
1809
+ </xsl:when>
1810
+ <xsl:otherwise>undefined</xsl:otherwise>
1811
+ </xsl:choose>
1812
+ <xsl:text>]</xsl:text>
1813
+ </xsl:template>
1814
+ <xsl:template match="*" mode="render-type"/>
1815
+ <xsl:template match="xsd:element | xsd:complexType | xsd:simpleType | xsd:complexContent"
1816
+ mode="render-type">
1817
+ <xsl:param name="anti.recursion"/>
1818
+ <xsl:apply-templates select="*" mode="render-type">
1819
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1820
+ </xsl:apply-templates>
1821
+ </xsl:template>
1822
+ <xsl:template match="xsd:restriction[ parent::xsd:simpleType ]" mode="render-type">
1823
+ <xsl:param name="anti.recursion"/>
1824
+ <xsl:variable name="type-local-name" select="substring-after(@base, ':')"/>
1825
+ <xsl:variable name="type-name">
1826
+ <xsl:choose>
1827
+ <xsl:when test="$type-local-name">
1828
+ <xsl:value-of select="$type-local-name"/>
1829
+ </xsl:when>
1830
+ <xsl:when test="@base">
1831
+ <xsl:value-of select="@base"/>
1832
+ </xsl:when>
1833
+ <xsl:otherwise>undefined</xsl:otherwise>
1834
+ </xsl:choose>
1835
+ </xsl:variable>
1836
+
1837
+ <xsl:text> - </xsl:text>
1838
+ <xsl:call-template name="render-type.write-name">
1839
+ <xsl:with-param name="type-local-name" select="$type-local-name"/>
1840
+ </xsl:call-template>
1841
+ <xsl:text> with </xsl:text>
1842
+ <xsl:value-of select="local-name()"/>
1843
+ <xsl:apply-templates select="*" mode="render-type">
1844
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1845
+ </xsl:apply-templates>
1846
+ </xsl:template>
1847
+ <xsl:template match="xsd:simpleType/xsd:restriction/xsd:*[not(self::xsd:enumeration)]"
1848
+ mode="render-type">
1849
+ <xsl:text> </xsl:text>
1850
+ <xsl:value-of select="local-name()"/>
1851
+ <xsl:text>(</xsl:text>
1852
+ <xsl:value-of select="@value"/>
1853
+ <xsl:text>)</xsl:text>
1854
+ </xsl:template>
1855
+ <xsl:template match="xsd:restriction | xsd:extension" mode="render-type">
1856
+ <xsl:param name="anti.recursion"/>
1857
+ <xsl:variable name="type-local-name" select="substring-after(@base, ':')"/>
1858
+ <xsl:variable name="type-name">
1859
+ <xsl:choose>
1860
+ <xsl:when test="$type-local-name">
1861
+ <xsl:value-of select="$type-local-name"/>
1862
+ </xsl:when>
1863
+ <xsl:when test="@base">
1864
+ <xsl:value-of select="@base"/>
1865
+ </xsl:when>
1866
+ <xsl:otherwise>undefined</xsl:otherwise>
1867
+ </xsl:choose>
1868
+ </xsl:variable>
1869
+ <xsl:variable name="base-type" select="$consolidated-xsd[@name = $type-name][1]"/>
1870
+ <xsl:variable name="abstract">
1871
+ <xsl:if test="$base-type/@abstract">abstract </xsl:if>
1872
+ </xsl:variable>
1873
+
1874
+ <xsl:if test="not($type-name = 'Array')">
1875
+ <xsl:value-of select="concat(' - ', local-name(), ' of ', $abstract)"/>
1876
+ <xsl:call-template name="render-type.write-name">
1877
+ <xsl:with-param name="type-local-name" select="$type-name"/>
1878
+ </xsl:call-template>
1879
+ </xsl:if>
1880
+
1881
+ <xsl:apply-templates select="$base-type | *" mode="render-type">
1882
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1883
+ </xsl:apply-templates>
1884
+ </xsl:template>
1885
+ <xsl:template match="xsd:attribute[ @*[local-name() = 'arrayType'] ]" mode="render-type">
1886
+ <xsl:param name="anti.recursion"/>
1887
+ <xsl:variable name="array-local-name"
1888
+ select="substring-after(@*[local-name() = 'arrayType'], ':')"/>
1889
+ <xsl:variable name="type-local-name" select="substring-before($array-local-name, '[')"/>
1890
+ <xsl:variable name="array-type" select="$consolidated-xsd[@name = $type-local-name][1]"/>
1891
+
1892
+ <xsl:text> - array of </xsl:text>
1893
+ <xsl:call-template name="render-type.write-name">
1894
+ <xsl:with-param name="type-local-name" select="$type-local-name"/>
1895
+ </xsl:call-template>
1896
+
1897
+ <xsl:apply-templates select="$array-type" mode="render-type">
1898
+ <xsl:with-param name="anti.recursion" select="$anti.recursion"/>
1899
+ </xsl:apply-templates>
1900
+ </xsl:template>
1901
+ <xsl:template match="xsd:enumeration" mode="render-type"/>
1902
+ <xsl:template match="xsd:enumeration[not(preceding-sibling::xsd:enumeration)]"
1903
+ mode="render-type">
1904
+ <xsl:text> - enum { </xsl:text>
1905
+ <xsl:apply-templates select="self::* | following-sibling::xsd:enumeration" mode="render-type.enum"/>
1906
+ <xsl:text> }</xsl:text>
1907
+ </xsl:template>
1908
+ <xsl:template match="xsd:enumeration" mode="render-type.enum">
1909
+ <xsl:if test="preceding-sibling::xsd:enumeration">
1910
+ <xsl:text>, </xsl:text>
1911
+ </xsl:if>
1912
+ <xsl:text disable-output-escaping="yes">'</xsl:text>
1913
+ <xsl:value-of select="@value"/>
1914
+ <xsl:text disable-output-escaping="yes">'</xsl:text>
1915
+ </xsl:template>
1916
+
1917
+ <!--
1918
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1919
+ End of included transformation: wsdl-viewer-xsd-tree.xsl
1920
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1921
+ -->
1922
+
1923
+
1924
+
1925
+ <!--
1926
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1927
+ Begin of included transformation: wsdl-viewer-src.xsl
1928
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
1929
+ -->
1930
+ <xsl:template match="@*" mode="src.import">
1931
+ <xsl:param name="src.import.stack"/>
1932
+ <xsl:variable name="recursion.label" select="concat('[', string(.), ']')"/>
1933
+ <xsl:variable name="recursion.check" select="concat($src.import.stack, $recursion.label)"/>
1934
+
1935
+ <xsl:choose>
1936
+ <xsl:when test="contains($src.import.stack, $recursion.label)">
1937
+ <h2 style="#87D300">
1938
+ <xsl:value-of select="concat('Cyclic include / import: ', $recursion.check)"/>
1939
+ </h2>
1940
+ </xsl:when>
1941
+ <xsl:otherwise>
1942
+ <h2>
1943
+ <a name="{concat($SRC-FILE-PREFIX, generate-id(..))}">
1944
+ <xsl:choose>
1945
+ <xsl:when test="parent::xsd:include">Included </xsl:when>
1946
+ <xsl:otherwise>Imported </xsl:otherwise>
1947
+ </xsl:choose>
1948
+
1949
+ <xsl:choose>
1950
+ <xsl:when test="name() = 'location'">WSDL </xsl:when>
1951
+ <xsl:otherwise>Schema </xsl:otherwise>
1952
+ </xsl:choose>
1953
+ <i>
1954
+ <xsl:value-of select="."/>
1955
+ </i>
1956
+ </a>
1957
+ </h2>
1958
+
1959
+ <div class="box">
1960
+ <xsl:apply-templates select="document(string(.))" mode="src"/>
1961
+ </div>
1962
+
1963
+ <xsl:apply-templates select="document(string(.))/*/*[local-name() = 'import'][@location]/@location"
1964
+ mode="src.import">
1965
+ <xsl:with-param name="src.import.stack" select="$recursion.check"/>
1966
+ </xsl:apply-templates>
1967
+ <xsl:apply-templates select="document(string(.))//xsd:import[@schemaLocation]/@schemaLocation"
1968
+ mode="src.import">
1969
+ <xsl:with-param name="src.import.stack" select="$recursion.check"/>
1970
+ </xsl:apply-templates>
1971
+ </xsl:otherwise>
1972
+ </xsl:choose>
1973
+ </xsl:template>
1974
+ <xsl:template match="*" mode="src">
1975
+ <div class="xml-element">
1976
+ <a name="{concat($SRC-PREFIX, generate-id(.))}">
1977
+ <xsl:apply-templates select="." mode="src.link"/>
1978
+ <xsl:apply-templates select="." mode="src.start-tag"/>
1979
+ </a>
1980
+ <xsl:apply-templates select="*|comment()|processing-instruction()|text()[string-length(normalize-space(.)) &gt; 0]"
1981
+ mode="src"/>
1982
+ <xsl:apply-templates select="." mode="src.end-tag"/>
1983
+ </div>
1984
+ </xsl:template>
1985
+ <xsl:template match="*" mode="src.start-tag">
1986
+ <xsl:call-template name="src.elem">
1987
+ <xsl:with-param name="src.elem.end-slash"> /</xsl:with-param>
1988
+ </xsl:call-template>
1989
+ </xsl:template>
1990
+ <xsl:template match="*[*|comment()|processing-instruction()|text()[string-length(normalize-space(.)) &gt; 0]]"
1991
+ mode="src.start-tag">
1992
+ <xsl:call-template name="src.elem"/>
1993
+ </xsl:template>
1994
+ <xsl:template match="*" mode="src.end-tag"/>
1995
+ <xsl:template match="*[*|comment()|processing-instruction()|text()[string-length(normalize-space(.)) &gt; 0]]"
1996
+ mode="src.end-tag">
1997
+ <xsl:call-template name="src.elem">
1998
+ <xsl:with-param name="src.elem.start-slash">/</xsl:with-param>
1999
+ </xsl:call-template>
2000
+ </xsl:template>
2001
+ <xsl:template match="*" mode="src.link-attribute">
2002
+ <xsl:if test="$ENABLE-LINK">
2003
+ <xsl:attribute name="href">
2004
+ <xsl:value-of select="concat('#', $SRC-PREFIX, generate-id(.))"/>
2005
+ </xsl:attribute>
2006
+ </xsl:if>
2007
+ </xsl:template>
2008
+ <xsl:template match="*[local-name() = 'import' or local-name() = 'include'][@location or @schemaLocation]"
2009
+ mode="src.link">
2010
+ <xsl:if test="$ENABLE-LINK">
2011
+ <xsl:attribute name="href">
2012
+ <xsl:value-of select="concat('#', $SRC-FILE-PREFIX, generate-id(.))"/>
2013
+ </xsl:attribute>
2014
+ </xsl:if>
2015
+ </xsl:template>
2016
+ <xsl:template match="*" mode="src.link"/>
2017
+ <xsl:template match="ws2:service|ws2:binding" mode="src.link">
2018
+ <xsl:variable name="iface-name">
2019
+ <xsl:apply-templates select="@interface" mode="qname.normalized"/>
2020
+ </xsl:variable>
2021
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface[@name = $iface-name]"
2022
+ mode="src.link-attribute"/>
2023
+ </xsl:template>
2024
+ <xsl:template match="ws2:endpoint" mode="src.link">
2025
+ <xsl:variable name="binding-name">
2026
+ <xsl:apply-templates select="@binding" mode="qname.normalized"/>
2027
+ </xsl:variable>
2028
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:binding[@name = $binding-name]"
2029
+ mode="src.link-attribute"/>
2030
+ </xsl:template>
2031
+ <xsl:template match="ws2:binding/ws2:operation" mode="src.link">
2032
+ <xsl:variable name="operation-name">
2033
+ <xsl:apply-templates select="@ref" mode="qname.normalized"/>
2034
+ </xsl:variable>
2035
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface/ws2:operation[@name = $operation-name]"
2036
+ mode="src.link-attribute"/>
2037
+ </xsl:template>
2038
+ <xsl:template match="ws2:binding/ws2:fault|ws2:interface/ws2:operation/ws2:infault|ws2:interface/ws2:operation/ws2:outfault"
2039
+ mode="src.link">
2040
+ <xsl:variable name="operation-name">
2041
+ <xsl:apply-templates select="@ref" mode="qname.normalized"/>
2042
+ </xsl:variable>
2043
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface/ws2:fault[@name = $operation-name]"
2044
+ mode="src.link-attribute"/>
2045
+ </xsl:template>
2046
+ <xsl:template match="ws2:interface/ws2:operation/ws2:input|ws2:interface/ws2:operation/ws2:output|ws2:interface/ws2:fault"
2047
+ mode="src.link">
2048
+ <xsl:variable name="elem-name">
2049
+ <xsl:apply-templates select="@element" mode="qname.normalized"/>
2050
+ </xsl:variable>
2051
+ <xsl:apply-templates select="$consolidated-xsd[@name = $elem-name]" mode="src.link-attribute"/>
2052
+ </xsl:template>
2053
+ <xsl:template match="ws:operation/ws:input[@message] | ws:operation/ws:output[@message] | ws:operation/ws:fault[@message] | soap:header[ancestor::ws:operation and @message]"
2054
+ mode="src.link">
2055
+ <xsl:apply-templates select="$consolidated-wsdl/ws:message[@name = substring-after( current()/@message, ':' )]"
2056
+ mode="src.link-attribute"/>
2057
+ </xsl:template>
2058
+ <xsl:template match="ws:operation/ws:input[@message] | ws:operation/ws:output[@message] | ws:operation/ws:fault[@message] | soap:header[ancestor::ws:operation and @message]"
2059
+ mode="src.link">
2060
+ <xsl:apply-templates select="$consolidated-wsdl/ws:message[@name = substring-after( current()/@message, ':' )]"
2061
+ mode="src.link-attribute"/>
2062
+ </xsl:template>
2063
+ <xsl:template match="ws:message/ws:part[@element or @type]" mode="src.link">
2064
+ <xsl:variable name="elem-local-name" select="substring-after(@element, ':')"/>
2065
+ <xsl:variable name="type-local-name" select="substring-after(@type, ':')"/>
2066
+ <xsl:variable name="elem-name">
2067
+ <xsl:choose>
2068
+ <xsl:when test="$elem-local-name">
2069
+ <xsl:value-of select="$elem-local-name"/>
2070
+ </xsl:when>
2071
+ <xsl:when test="$type-local-name">
2072
+ <xsl:value-of select="$type-local-name"/>
2073
+ </xsl:when>
2074
+ <xsl:when test="@element">
2075
+ <xsl:value-of select="@element"/>
2076
+ </xsl:when>
2077
+ <xsl:when test="@type">
2078
+ <xsl:value-of select="@type"/>
2079
+ </xsl:when>
2080
+ <xsl:otherwise>
2081
+ <xsl:call-template name="src.syntax-error"/>
2082
+ </xsl:otherwise>
2083
+ </xsl:choose>
2084
+ </xsl:variable>
2085
+
2086
+ <xsl:apply-templates select="$consolidated-xsd[@name = $elem-name]" mode="src.link-attribute"/>
2087
+ </xsl:template>
2088
+ <xsl:template match="ws:service/ws:port[@binding]" mode="src.link">
2089
+ <xsl:variable name="binding-name">
2090
+ <xsl:apply-templates select="@binding" mode="qname.normalized"/>
2091
+ </xsl:variable>
2092
+ <xsl:apply-templates select="$consolidated-wsdl/ws:binding[@name = $binding-name]"
2093
+ mode="src.link-attribute"/>
2094
+ </xsl:template>
2095
+ <xsl:template match="ws:operation[@name and parent::ws:binding/@type]" mode="src.link">
2096
+ <xsl:variable name="type-name">
2097
+ <xsl:apply-templates select="../@type" mode="qname.normalized"/>
2098
+ </xsl:variable>
2099
+ <xsl:apply-templates select="$consolidated-wsdl/ws:portType[@name = $type-name]/ws:operation[@name = current()/@name]"
2100
+ mode="src.link-attribute"/>
2101
+ </xsl:template>
2102
+ <xsl:template match="xsd:element[@ref or @type]" mode="src.link">
2103
+ <xsl:variable name="ref-or-type">
2104
+ <xsl:choose>
2105
+ <xsl:when test="@type">
2106
+ <xsl:value-of select="@type"/>
2107
+ </xsl:when>
2108
+ <xsl:otherwise>
2109
+ <xsl:value-of select="@ref"/>
2110
+ </xsl:otherwise>
2111
+ </xsl:choose>
2112
+ </xsl:variable>
2113
+
2114
+ <xsl:variable name="type-local-name" select="substring-after($ref-or-type, ':')"/>
2115
+ <xsl:variable name="xsd-name">
2116
+ <xsl:choose>
2117
+ <xsl:when test="$type-local-name">
2118
+ <xsl:value-of select="$type-local-name"/>
2119
+ </xsl:when>
2120
+ <xsl:when test="$ref-or-type">
2121
+ <xsl:value-of select="$ref-or-type"/>
2122
+ </xsl:when>
2123
+ <xsl:otherwise/>
2124
+ </xsl:choose>
2125
+ </xsl:variable>
2126
+
2127
+ <xsl:if test="$xsd-name">
2128
+ <xsl:variable name="msg"
2129
+ select="$consolidated-xsd[@name = $xsd-name and contains(local-name(), 'Type')][1]"/>
2130
+ <xsl:apply-templates select="$msg" mode="src.link-attribute"/>
2131
+ </xsl:if>
2132
+ </xsl:template>
2133
+ <xsl:template match="xsd:attribute[contains(@ref, 'arrayType')]" mode="src.link">
2134
+ <xsl:variable name="att-array-type"
2135
+ select="substring-before(@*[local-name() = 'arrayType'], '[]')"/>
2136
+ <xsl:variable name="xsd-local-name" select="substring-after($att-array-type, ':')"/>
2137
+ <xsl:variable name="xsd-name">
2138
+ <xsl:choose>
2139
+ <xsl:when test="$xsd-local-name">
2140
+ <xsl:value-of select="$xsd-local-name"/>
2141
+ </xsl:when>
2142
+ <xsl:otherwise>
2143
+ <xsl:value-of select="$att-array-type"/>
2144
+ </xsl:otherwise>
2145
+ </xsl:choose>
2146
+ </xsl:variable>
2147
+ <xsl:if test="$xsd-name">
2148
+ <xsl:variable name="msg" select="$consolidated-xsd[@name = $xsd-name][1]"/>
2149
+ <xsl:apply-templates select="$msg" mode="src.link-attribute"/>
2150
+ </xsl:if>
2151
+ </xsl:template>
2152
+ <xsl:template match="xsd:extension | xsd:restriction" mode="src.link">
2153
+ <xsl:variable name="xsd-local-name" select="substring-after(@base, ':')"/>
2154
+ <xsl:variable name="xsd-name">
2155
+ <xsl:choose>
2156
+ <xsl:when test="$xsd-local-name">
2157
+ <xsl:value-of select="$xsd-local-name"/>
2158
+ </xsl:when>
2159
+ <xsl:otherwise>
2160
+ <xsl:value-of select="@type"/>
2161
+ </xsl:otherwise>
2162
+ </xsl:choose>
2163
+ </xsl:variable>
2164
+ <xsl:variable name="msg" select="$consolidated-xsd[@name = $xsd-name][1]"/>
2165
+ <xsl:apply-templates select="$msg" mode="src.link-attribute"/>
2166
+ </xsl:template>
2167
+ <xsl:template name="src.elem">
2168
+ <xsl:param name="src.elem.start-slash"/>
2169
+ <xsl:param name="src.elem.end-slash"/>
2170
+
2171
+ <xsl:value-of select="concat('&lt;', $src.elem.start-slash, name(.))"
2172
+ disable-output-escaping="no"/>
2173
+ <xsl:if test="not($src.elem.start-slash)">
2174
+ <xsl:apply-templates select="@*" mode="src"/>
2175
+ <xsl:apply-templates select="." mode="src.namespace"/>
2176
+ </xsl:if>
2177
+ <xsl:value-of select="concat($src.elem.end-slash, '&gt;')" disable-output-escaping="no"/>
2178
+ </xsl:template>
2179
+ <xsl:template match="@*" mode="src">
2180
+ <xsl:text> </xsl:text>
2181
+ <span class="xml-att">
2182
+ <xsl:value-of select="concat(name(), '=')"/>
2183
+ <span class="xml-att-val">
2184
+ <xsl:value-of select="concat('&#34;', ., '&#34;')" disable-output-escaping="yes"/>
2185
+ </span>
2186
+ </span>
2187
+ </xsl:template>
2188
+ <xsl:template match="*" mode="src.namespace">
2189
+ <xsl:variable name="supports-namespace-axis" select="count(/*/namespace::*) &gt; 0"/>
2190
+ <xsl:variable name="current" select="current()"/>
2191
+
2192
+ <xsl:choose>
2193
+ <xsl:when test="count(/*/namespace::*) &gt; 0">
2194
+ <!--
2195
+ When the namespace axis is present (e.g. Internet Explorer), we can simulate
2196
+ the namespace declarations by comparing the namespaces in scope on this element
2197
+ with those in scope on the parent element. Any difference must have been the
2198
+ result of a namespace declaration. Note that this doesn't reflect the actual
2199
+ source - it will strip out redundant namespace declarations.
2200
+ -->
2201
+ <xsl:for-each select="namespace::*[. != 'http://www.w3.org/XML/1998/namespace']">
2202
+ <xsl:if test="not($current/parent::*[namespace::*[. = current()]])">
2203
+ <div class="xml-att">
2204
+ <xsl:text> xmlns</xsl:text>
2205
+ <xsl:if test="string-length(name())">:</xsl:if>
2206
+ <xsl:value-of select="concat(name(), '=')"/>
2207
+ <span class="xml-att-val">
2208
+ <xsl:value-of select="concat('&#34;', ., '&#34;')" disable-output-escaping="yes"/>
2209
+ </span>
2210
+ </div>
2211
+ </xsl:if>
2212
+ </xsl:for-each>
2213
+ </xsl:when>
2214
+ <xsl:otherwise>
2215
+ <!--
2216
+ When the namespace axis isn't supported (e.g. Mozilla), we can simulate
2217
+ appropriate declarations from namespace elements.
2218
+ This currently doesn't check for namespaces on attributes.
2219
+ In the general case we can't reliably detect the use of QNames in content, but
2220
+ in the case of schema, we know which content could contain a QName and look
2221
+ there too. This mechanism is rather unpleasant though, since it records
2222
+ namespaces where they are used rather than showing where they are declared
2223
+ (on some parent element) in the source. Yukk!
2224
+ -->
2225
+ <xsl:if test="namespace-uri(.) != namespace-uri(parent::*) or not(parent::*)">
2226
+ <span class="xml-att">
2227
+ <xsl:text> xmlns</xsl:text>
2228
+ <xsl:if test="substring-before(name(),':') != ''">:</xsl:if>
2229
+ <xsl:value-of select="substring-before(name(),':')"/>
2230
+ <xsl:text>=</xsl:text>
2231
+ <span class="xml-att-val">
2232
+ <xsl:value-of select="concat('&#34;', namespace-uri(.), '&#34;')" disable-output-escaping="yes"/>
2233
+ </span>
2234
+ </span>
2235
+ </xsl:if>
2236
+ </xsl:otherwise>
2237
+ </xsl:choose>
2238
+
2239
+ </xsl:template>
2240
+ <xsl:template match="text()" mode="src">
2241
+ <span class="xml-text">
2242
+ <xsl:value-of select="." disable-output-escaping="no"/>
2243
+ </span>
2244
+ </xsl:template>
2245
+ <xsl:template match="comment()" mode="src">
2246
+ <div class="xml-comment">
2247
+ <xsl:text disable-output-escaping="no">&lt;!-- </xsl:text>
2248
+ <xsl:value-of select="." disable-output-escaping="no"/>
2249
+ <xsl:text disable-output-escaping="no"> --&gt;
2250
+ </xsl:text>
2251
+ </div>
2252
+ </xsl:template>
2253
+ <xsl:template match="processing-instruction()" mode="src">
2254
+ <div class="xml-proc">
2255
+ <xsl:text disable-output-escaping="no">&lt;?</xsl:text>
2256
+ <xsl:copy-of select="name(.)"/>
2257
+ <xsl:value-of select="concat(' ', .)" disable-output-escaping="yes"/>
2258
+ <xsl:text disable-output-escaping="no"> ?&gt;
2259
+ </xsl:text>
2260
+ </div>
2261
+ </xsl:template>
2262
+
2263
+ <!--
2264
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
2265
+ End of included transformation: wsdl-viewer-src.xsl
2266
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
2267
+ -->
2268
+
2269
+
2270
+
2271
+
2272
+
2273
+ <!--
2274
+ ==================================================================
2275
+ Starting point
2276
+ ==================================================================
2277
+ -->
2278
+
2279
+ <xsl:template match="/">
2280
+ <html>
2281
+ <xsl:call-template name="head.render"/>
2282
+ <xsl:call-template name="body.render"/>
2283
+ </html>
2284
+ </xsl:template>
2285
+
2286
+
2287
+
2288
+ <!--
2289
+ ==================================================================
2290
+ Rendering: HTML head
2291
+ ==================================================================
2292
+ -->
2293
+
2294
+ <xsl:template name="head.render">
2295
+ <head>
2296
+ <title>
2297
+ <xsl:value-of select="$html-title"/>
2298
+ </title>
2299
+ <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
2300
+ <meta http-equiv="content-script-type" content="text/javascript"/>
2301
+ <meta http-equiv="content-style-type" content="text/css"/>
2302
+ <meta name="Generator" content="http://tomi.vanek.sk/xml/wsdl-viewer.xsl"/>
2303
+
2304
+ <meta http-equiv="imagetoolbar" content="false"/>
2305
+ <meta name="MSSmartTagsPreventParsing" content="true"/>
2306
+
2307
+ <style type="text/css">
2308
+ <xsl:value-of select="$css" disable-output-escaping="yes"/>
2309
+ </style>
2310
+ </head>
2311
+ </xsl:template>
2312
+
2313
+
2314
+
2315
+ <!--
2316
+ ==================================================================
2317
+ Rendering: HTML body
2318
+ ==================================================================
2319
+ -->
2320
+
2321
+ <xsl:template name="body.render">
2322
+ <body id="operations">
2323
+ <div id="outer_box">
2324
+ <div id="inner_box" onload="pagingInit()">
2325
+ <xsl:call-template name="title.render"/>
2326
+
2327
+
2328
+ <!-- TODO: pages with tabs for selecting some aspect of the WSDL
2329
+ <xsl:call-template name="navig.render"/>
2330
+ -->
2331
+
2332
+ <xsl:call-template name="content.render"/>
2333
+ <xsl:call-template name="footer.render"/>
2334
+ </div>
2335
+ </div>
2336
+ </body>
2337
+ </xsl:template>
2338
+
2339
+
2340
+
2341
+ <!--
2342
+ ==================================================================
2343
+ Rendering: heading
2344
+ ==================================================================
2345
+ -->
2346
+
2347
+ <xsl:template name="title.render">
2348
+ <div id="header" style="height:4em; line-height:8em;">
2349
+ <h1>
2350
+ <table>
2351
+ <tr valign="middle">
2352
+ <td><a href="http://www.onvif.org"><img align="left" src="/logo.gif" style="border-width: 0px;" alt="ONVIF" height="60" /></a></td>
2353
+ <td width="100%" align="center"><xsl:value-of select="$consolidated-wsdl/@targetNamespace"/><br /></td>
2354
+ <td width="100%" align="right"><xsl:value-of select="$consolidated-wsdl/ws:types/xsd:schema/@version"/></td>
2355
+ </tr>
2356
+ </table>
2357
+ </h1>
2358
+ </div>
2359
+ </xsl:template>
2360
+
2361
+
2362
+
2363
+ <!--
2364
+ ==================================================================
2365
+ Rendering: navigation
2366
+ ==================================================================
2367
+ -->
2368
+
2369
+ <xsl:template name="navig.render">
2370
+ <div id="outer_nav">
2371
+ <div id="nav" class="floatcontainer">
2372
+ <ul>
2373
+ <li id="nav-service">
2374
+ <a href="#page.service">Service</a>
2375
+ </li>
2376
+ <li id="nav-operations">
2377
+ <a href="#page.operations">Operations</a>
2378
+ </li>
2379
+ <li id="nav-wsdl">
2380
+ <a href="#page.src">Source Code</a>
2381
+ </li>
2382
+
2383
+
2384
+ <!-- <li id="nav-client"><a href="#TODO-1">Client</a></li>
2385
+ -->
2386
+
2387
+ <li id="nav-about">
2388
+ <a href="#page.about" class="current">About</a>
2389
+ </li>
2390
+ </ul>
2391
+ </div>
2392
+ </div>
2393
+ </xsl:template>
2394
+
2395
+
2396
+
2397
+ <!--
2398
+ ==================================================================
2399
+ Rendering: content
2400
+ ==================================================================
2401
+ -->
2402
+
2403
+ <xsl:template name="content.render">
2404
+ <div id="content">
2405
+ <xsl:if test="$ENABLE-SERVICE-PARAGRAPH">
2406
+ <xsl:call-template name="service.render"/>
2407
+ </xsl:if>
2408
+ <xsl:if test="$ENABLE-OPERATIONS-PARAGRAPH">
2409
+ <xsl:call-template name="operations.render"/>
2410
+ </xsl:if>
2411
+ <xsl:if test="$ENABLE-SRC-CODE-PARAGRAPH">
2412
+ <xsl:call-template name="src.render"/>
2413
+ </xsl:if>
2414
+ <xsl:if test="$ENABLE-ABOUT-PARAGRAPH">
2415
+ <xsl:call-template name="about.render">
2416
+ <xsl:with-param name="version" select="$wsdl-viewer.version"/>
2417
+ </xsl:call-template>
2418
+ </xsl:if>
2419
+ </div>
2420
+ </xsl:template>
2421
+
2422
+
2423
+
2424
+ <!--
2425
+ ==================================================================
2426
+ Rendering: footer
2427
+ ==================================================================
2428
+ -->
2429
+
2430
+ <xsl:template name="footer.render">
2431
+ <div id="footer">
2432
+ <table width="100%"><tr><td style="font-size:125%">
2433
+ This informative document is based on the ONVIF Core Secification - Copyright ONVIF.
2434
+ </td><td align="right">
2435
+ Page generation based on wsdl-viewer.xsl (<a href="http://tomi.vanek.sk">http://tomi.vanek.sk</a>)
2436
+ </td></tr>
2437
+ </table>
2438
+ </div>
2439
+ </xsl:template>
2440
+
2441
+
2442
+
2443
+ <!--
2444
+ ==================================================================
2445
+ Rendering: WSDL service information
2446
+ ==================================================================
2447
+ -->
2448
+
2449
+ <xsl:template name="service.render">
2450
+ <div class="page">
2451
+ <!-- Suppress binding output
2452
+ <a class="target" name="page.service">
2453
+ <h2>
2454
+ <xsl:value-of select="$html-title"/>
2455
+ </h2>
2456
+ </a>
2457
+ -->
2458
+ <xsl:apply-templates select="$consolidated-wsdl/*[local-name(.) = 'documentation']"
2459
+ mode="documentation.render"/>
2460
+ <xsl:apply-templates select="$consolidated-wsdl/ws:service|$consolidated-wsdl/ws2:service"
2461
+ mode="service-start"/>
2462
+ <xsl:if test="not($consolidated-wsdl/*[local-name() = 'service']/@name)">
2463
+
2464
+
2465
+ <!-- If the WS is without implementation, just with binding points = WS interface -->
2466
+
2467
+ <xsl:apply-templates select="$consolidated-wsdl/ws:binding" mode="service-start"/>
2468
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface" mode="service"/>
2469
+ </xsl:if>
2470
+ </div>
2471
+ </xsl:template>
2472
+
2473
+
2474
+
2475
+ <!--
2476
+ ==================================================================
2477
+ Rendering: WSDL operations - detail
2478
+ ==================================================================
2479
+ -->
2480
+
2481
+ <xsl:template name="operations.render">
2482
+ <div class="page">
2483
+ <a class="target" name="page.operations">
2484
+ <h2>Operations</h2>
2485
+ </a>
2486
+ <ul>
2487
+ <xsl:apply-templates select="$consolidated-wsdl/ws:portType" mode="operations">
2488
+ <xsl:sort select="@name"/>
2489
+ </xsl:apply-templates>
2490
+
2491
+ <xsl:choose>
2492
+ <xsl:when test="$consolidated-wsdl/*[local-name() = 'service']/@name">
2493
+ <xsl:variable name="iface-name">
2494
+ <xsl:apply-templates select="$consolidated-wsdl/*[local-name() = 'service']/@interface"
2495
+ mode="qname.normalized"/>
2496
+ </xsl:variable>
2497
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface[@name = $iface-name]"
2498
+ mode="operations">
2499
+ <xsl:sort select="@name"/>
2500
+ </xsl:apply-templates>
2501
+ </xsl:when>
2502
+ <xsl:when test="$consolidated-wsdl/ws2:interface/@name">
2503
+
2504
+
2505
+ <!-- TODO: What to do if there are more interfaces? -->
2506
+
2507
+ <xsl:apply-templates select="$consolidated-wsdl/ws2:interface[1]" mode="operations"/>
2508
+ </xsl:when>
2509
+ <xsl:otherwise>
2510
+
2511
+
2512
+ <!-- TODO: Error message or handling somehow this unexpected situation -->
2513
+
2514
+ </xsl:otherwise>
2515
+ </xsl:choose>
2516
+ </ul>
2517
+ </div>
2518
+ </xsl:template>
2519
+
2520
+
2521
+
2522
+ <!--
2523
+ ==================================================================
2524
+ Rendering: WSDL and XSD source code files
2525
+ ==================================================================
2526
+ -->
2527
+
2528
+ <xsl:template name="src.render">
2529
+ <div class="page">
2530
+ <a class="target" name="page.src">
2531
+ <h2>WSDL source code</h2>
2532
+ </a>
2533
+ <div class="box">
2534
+ <div class="xml-proc">
2535
+ <xsl:text>&lt;?xml version="1.0"?&gt;</xsl:text>
2536
+ </div>
2537
+ <xsl:apply-templates select="/" mode="src"/>
2538
+ </div>
2539
+
2540
+ <xsl:apply-templates select="/*/*[local-name() = 'import'][@location]/@location" mode="src.import"/>
2541
+ <xsl:apply-templates select="$consolidated-wsdl/*[local-name() = 'types']//xsd:import[@schemaLocation]/@schemaLocation | $consolidated-wsdl/*[local-name() = 'types']//xsd:include[@schemaLocation]/@schemaLocation"
2542
+ mode="src.import"/>
2543
+ </div>
2544
+ </xsl:template>
2545
+
2546
+
2547
+
2548
+ <!--
2549
+ ==================================================================
2550
+ Rendering: About
2551
+ ==================================================================
2552
+ -->
2553
+
2554
+ <xsl:template name="about.render">
2555
+ <xsl:param name="version"/>
2556
+ <!--<div class="page">
2557
+ <a class="target" name="page.about">
2558
+ <h2>About <em>wsdl-viewer.xsl</em>
2559
+ </h2>
2560
+ </a>
2561
+ <div class="floatcontainer">
2562
+ <div id="fix_column">
2563
+ <div class="shadow">
2564
+ <div class="box">
2565
+ <xsl:call-template name="processor-info.render"/>
2566
+ </div>
2567
+ </div>
2568
+ </div>
2569
+
2570
+ <div id="flexi_column">
2571
+ <xsl:call-template name="about.detail">
2572
+ <xsl:with-param name="version" select="$wsdl-viewer.version"/>
2573
+ </xsl:call-template>
2574
+ </div>
2575
+ </div>
2576
+ </div>-->
2577
+ </xsl:template>
2578
+
2579
+
2580
+ </xsl:stylesheet>