Subversion Repositories XServices

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
159 brianR 1
<?xml version='1.0' encoding='utf-8'?>
2
<!DOCTYPE section [
3
<!ENTITY % myent SYSTEM "../entities.ent">
4
%myent;
5
]>
6
<section xmlns="http://docbook.org/ns/docbook" version="5.0"
7
	xmlns:xi="http://www.w3.org/2001/XInclude">
8
	<title>insertNodes</title>
9
	<para>Insert an xml fragment into other elements specified by an XPath expression.
10
	This operation is namespace aware.
11
 
12
	Sample request:
13
<programlisting language="xml"><![CDATA[
14
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.xservices.brutex.net">
15
   <soapenv:Header/>
16
   <soapenv:Body>
17
      <ws:insertNodes>
18
         <sourcexml><![CDATA[
19
         <books>
20
			<author>
21
				<name>Mensiok</name>
22
				<surname>Bello</surname>
23
			</author>
24
			<author>
25
				<name>Schwab</name>
26
				<surname>Rumsau</surname>
27
			</author>
28
			<author>
29
				<name>Dollibert</name>
30
				<surname>Rach</surname>
31
			</author>
32
         </books>
33
         ]]]]><![CDATA[></sourcexml>
34
         <encoding>utf-8</encoding>
35
         <namespaceList>
36
            <!--Zero or more repetitions:-->
37
            <namespace>
38
               <prefix></prefix>
39
               <uri></uri>
40
            </namespace>
41
         </namespaceList>
42
         <xpath>/books/author</xpath>
43
         <!--Optional:-->
44
         <xmldata><![CDATA[<age namespace="http://btx"/>]]]]><![CDATA[></xmldata>
45
      </ws:insertNodes>
46
   </soapenv:Body>
47
</soapenv:Envelope>
48
]]></programlisting>
49
	Sample response:
50
	<programlisting language="xml"><![CDATA[
51
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
52
   <soap:Body>
53
      <ns2:insertNodesResponse xmlns:ns2="http://ws.xservices.brutex.net">
54
         <return><![CDATA[<?xml version='1.0' encoding='UTF-8'?>
55
         <books>
56
			<author>
57
				<name>Mensiok</name>
58
				<surname>Bello</surname>
59
			<age namespace="http://btx"/></author>
60
			<author>
61
				<name>Schwab</name>
62
				<surname>Rumsau</surname>
63
			<age namespace="http://btx"/></author>
64
			<author>
65
				<name>Dollibert</name>
66
				<surname>Rach</surname>
67
			<age namespace="http://btx"/></author>
68
         </books>]]]]><![CDATA[></!></return>
69
      </ns2:insertNodesResponse>
70
   </soap:Body>
71
</soap:Envelope>
72
]]></programlisting>
73
</para>
74
</section>