- From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
- Date: Tue, 06 Jan 2004 14:47:56 +0000
- To: Mithun Sheshagiri <mits1@csee.umbc.edu>
- Cc: xmlschema-dev@w3.org
Mithun Sheshagiri <mits1@csee.umbc.edu> writes:
> Hi all,
> I am trying to enclose RDF in SOAP body of my response messages.
> The schema I am using for the RDF is as follows:
<snip/>
> The service accepts a keyword and outputs ItemList. The SOAP response
> looks like this:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <soapenv:Envelope
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> <soapenv:Body>
> <RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
> <ns2:ItemList ns1:ID="instanceOfItemList"
> xmlns:ns1="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
> xmlns:ns2="http://effects.com/">
> <ns2:member ns1:resource="http://thisone"/>
> <ns2:member ns1:resource="http://thistwo"/>
> </ns2:ItemList>
> <ns3:keyword xsi:nil="true" xmlns:ns3="http://effects.com/"/>
> </RDF>
> </soapenv:Body>
> </soapenv:Envelope>
>
> I want to extract the RDF/XML from this message and assert it into my
> KB. There is a problem though: the keyword element has a xsi namespace
> which is declared within the Envelope element. I want to move it to
> the RDF element. What changes should I make to the schema?
None. There's no way with a schema to enforce where namespaces are
declared. Any conformant XML application which serialises a subtree
(e.g. XSLT, XInclude, XQuery) will have to include namespace bindings
for all namespaces used in that subtree. You shouldn't have to do
anything, in other words.
ht
--
Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
Half-time member of W3C Team
2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk
URL: http://www.ltg.ed.ac.uk/~ht/
[mail really from me _always_ has this .sig -- mail without it is forged spam]
Received on Tuesday, 6 January 2004 09:47:57 UTC