Check-in [bc60d4585a]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Added documentation on how type casting of abstract to concrete types works.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk | Release_2.3.2
Files: files | file ages | folders
SHA1: bc60d4585a588cd1be04b41078ccf48cdde417bb
User & Date: gerald 2013-04-10 03:10:11.233
Context
2013-04-19 21:44
Fixed bug to get qualified namespace. check-in: 7ae81cabfb user: gerald tags: trunk
2013-04-10 03:10
Added documentation on how type casting of abstract to concrete types works. check-in: bc60d4585a user: gerald tags: trunk, Release_2.3.2
2013-04-10 02:38
Added details for special namespace attributes. check-in: f77791f44f user: gerald tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to docs/Calling_a_Web_Service.html.
41
42
43
44
45
46
47
48
49


50
51
52
53
54
55
56
57
        separate success and error callbacks</SPAN></A>
        <LI class=toclevel-1><A href="#Creation_of_stub_Tcl_procedures_to_make_synchronous_calls"><SPAN
        class=tocnumber>10</SPAN> <SPAN class=toctext>Creation of stub Tcl
        procedures to make synchronous calls</SPAN></A>
        <LI class=toclevel-1><A href="#Synchronous_Call_returning_the_raw_XML"><SPAN
        class=tocnumber>11</SPAN> <SPAN class=toctext>Synchronous Call returning
        the raw XML</SPAN></A> </li>
<li class="toclevel-1"><a href="#Config"><span class="tocnumber">12</span>
        <span class="toctext">Configuring Services</span></a>


</LI></UL></TD></TR></TBODY></TABLE>
<P>

</P>
<A name=Overview></A>
<H2>Overview </H2>
<P>The Webservices Client package provides a several ways to define what
operations a remote Web Services Server provides and how to call those







|
|
>
>
|







41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
        separate success and error callbacks</SPAN></A>
        <LI class=toclevel-1><A href="#Creation_of_stub_Tcl_procedures_to_make_synchronous_calls"><SPAN
        class=tocnumber>10</SPAN> <SPAN class=toctext>Creation of stub Tcl
        procedures to make synchronous calls</SPAN></A>
        <LI class=toclevel-1><A href="#Synchronous_Call_returning_the_raw_XML"><SPAN
        class=tocnumber>11</SPAN> <SPAN class=toctext>Synchronous Call returning
        the raw XML</SPAN></A> </li>
        <li class="toclevel-1"><a href="#Config"><span class="tocnumber">12</span>
        <span class="toctext">Configuring Services</span></a> </LI>
        <li class="toclevel-1"><a href="#TypeCasting"><span class="tocnumber">13</span>
        <span class="toctext">Dealing With Casting Abstract Types to Concrete Types</span></a> </LI>
      </UL></TD></TR></TBODY></TABLE>
<P>

</P>
<A name=Overview></A>
<H2>Overview </H2>
<P>The Webservices Client package provides a several ways to define what
operations a remote Web Services Server provides and how to call those
346
347
348
349
350
351
352



















353
354
355
</ul>
     <i>value</i>         - Optional, the new value.
</pre>
<p><b>Returns&nbsp;:</b> </p><pre>     The value of the item.
<p><b>Side-Effects&nbsp;: None</b> </p>
<p><b>Exception Conditions&nbsp;&nbsp;: None</b> </p>
<p><b>Pre-requisite Conditions&nbsp;: Service must have been defined.</b> </p></pre><p></p>



















</div>
</BODY>
</HTML>







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>



348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
</ul>
     <i>value</i>         - Optional, the new value.
</pre>
<p><b>Returns&nbsp;:</b> </p><pre>     The value of the item.
<p><b>Side-Effects&nbsp;: None</b> </p>
<p><b>Exception Conditions&nbsp;&nbsp;: None</b> </p>
<p><b>Pre-requisite Conditions&nbsp;: Service must have been defined.</b> </p></pre><p></p>


<p><a name="TypeCasting"></a>
</p><h2>Dealing With Casting Abstract Types to Concrete Types </h2>
<p>
    If you turn on <i>parseInAttr</i> and <i>genOutAttr</i>, the system will
    semi-automatically deal with casting of elements declared as a being of a
    type that is an abstract type to/from the concrete type actually to be used
    in a message.  On an element that is decleared to be a type which is an
    abstract type, the value of the <b>::type</b> key in the dictionary will
    specify the concrete type to be actually used (or for a reply message the
    concrete type that was actually used).
</p>
<p>
    <B>NOTE:</B> While in the WSDL the concreate type must be an extention
    of the abstract type, the package does not enforce this restriction, so
    caution must be taken.
</p>

</div>
</BODY>
</HTML>
Changes to docs/Dictionary_Representation_of_XML_Arrays.html.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<!DOCTYPE html>
<html><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Web Services for Tcl (aka tclws): Dictionary Representation of XML Arrays</title>
<link rel="stylesheet" href="style.css" type="text/css" media="screen">
</head>
<body>
<p>
XML arrays are represented in dictionary format as a list of values.  
Lets consider what this looks like for a 
&lt;href="#SimpleTypeArray"&gt;simple type&lt;/href&gt; and for a 
&lt;href="#ComplexTypeArray"&gt;complex type&lt;/href&gt;.
</p>

<p><a name="SimpleTypeArray"></a>
</p><h3>Array of Simple Type</h3>
<p>
Lets assume we have an element with the following definition:
</p><pre class="verbatim">    &lt;xs:element minOccurs="0" maxOccurs="unbounded" name="Primes" type="xs:integer" /&gt;
</pre>
Lets also assume that we will have that element in our dictionary with 
the first four prime numbers, thus the dictionary representation for 
that element would look like:
<pre class="verbatim">    Primes {2 3 5 7}
</pre>
Or, if we have are using attributes (i.e. parseInAttr and/or genOutAttr are set), it would look like:
<pre class="verbatim">    Primes {{} {2 3 5 7}}
</pre>
<p></p>








|
|
|
|








|
|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<!DOCTYPE html>
<html><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Web Services for Tcl (aka tclws): Dictionary Representation of XML Arrays</title>
<link rel="stylesheet" href="style.css" type="text/css" media="screen">
</head>
<body>
<p>
XML arrays are represented in dictionary format as a list of values.
Lets consider what this looks like for a
<a href="#SimpleTypeArray">simple type</a> and for a
<a href="#ComplexTypeArray">complex type</a>;.
</p>

<p><a name="SimpleTypeArray"></a>
</p><h3>Array of Simple Type</h3>
<p>
Lets assume we have an element with the following definition:
</p><pre class="verbatim">    &lt;xs:element minOccurs="0" maxOccurs="unbounded" name="Primes" type="xs:integer" /&gt;
</pre>
Lets also assume that we will have that element in our dictionary with
the first four prime numbers, thus the dictionary representation for
that element would look like:
<pre class="verbatim">    Primes {2 3 5 7}
</pre>
Or, if we have are using attributes (i.e. parseInAttr and/or genOutAttr are set), it would look like:
<pre class="verbatim">    Primes {{} {2 3 5 7}}
</pre>
<p></p>