[prev in list] [next in list] [prev in thread] [next in thread] 

List:       xerces-j-dev
Subject:    Re: honour-all-schemaLocations feature
From:       Michael Glavassevich <mrglavas () ca ! ibm ! com>
Date:       2009-10-25 3:45:19
Message-ID: OF36FDFA75.374CDBCE-ON8525765A.001321B9-8525765A.0014A1AD () ca ! ibm ! com
[Download RAW message or body]

Stanimir Stamenkov <s7an10@netscape.net> wrote on 10/24/2009 11:12:16 A=
M:

> Wed, 21 Oct 2009 14:34:25 -0700, /Jitendra Kotamraju/:
> > Stanimir Stamenkov wrote:
> >
> >> I guess one could prepare a source schema which contains only
> >> <xsd:import>s of the given <xsd:schema> elements.  The <xsd:import=
>
> >> locations could use custom URIs like "urn:x-jax-ws-import-a",
> >> "urn:x-jax-ws-import-b" which would be resolved by a custom resour=
ce
> >> resolver.  I think the "honour-all-schemaLocations" feature should=

> >> work this way.
> >
> > Yes, I was thinking the same to create a pseudo schema comprising o=
f
all
> > the schema fragements <types>/<xsd:schema> in the wsdl(but it is bi=
t of

> > a work, since those imports also need to have correct namespace etc=
).
>
> The <xsd:import>s need to have 'namespace' attribute with value of
> the 'targetNamespace' of the corresponding <xsd:schema> element, but
> that's not awful lot of work, IMO.

If you're synthesizing schema documents to glue together the ones in th=
e
WSDL then you may not even need to use "honour-all-schemaLocations". Cr=
eate
a schema document for each namespace with <xs:include>s (for each schem=
a
document in the WSDL with that target namespace) and then combine those=

together with <xs:import>s for each of those namespaces in a "master"
schema document. That should work with any schema processor, not just t=
hose
which honour multiple imports for the same namespace.

> --
> Stanimir
>
> ---------------------------------------------------------------------=

> To unsubscribe, e-mail: j-users-unsubscribe@xerces.apache.org
> For additional commands, e-mail: j-users-help@xerces.apache.org

Thanks.

Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: mrglavas@ca.ibm.com
E-mail: mrglavas@apache.org=

[Attachment #3 (text/html)]

<html><body>
<p><tt>Stanimir Stamenkov &lt;s7an10@netscape.net&gt; wrote on 10/24/20=
09 11:12:16 AM:<br>
<br>
&gt; Wed, 21 Oct 2009 14:34:25 -0700, /Jitendra Kotamraju/:<br>
&gt; &gt; Stanimir Stamenkov wrote:<br>
&gt; &gt;<br>
&gt; &gt;&gt; I guess one could prepare a source schema which contains =
only <br>
&gt; &gt;&gt; &lt;xsd:import&gt;s of the given &lt;xsd:schema&gt; eleme=
nts. &nbsp;The &lt;xsd:import&gt; <br>
&gt; &gt;&gt; locations could use custom URIs like &quot;urn:x-jax-ws-i=
mport-a&quot;, <br>
&gt; &gt;&gt; &quot;urn:x-jax-ws-import-b&quot; which would be resolved=
 by a custom resource <br>
&gt; &gt;&gt; resolver. &nbsp;I think the &quot;honour-all-schemaLocati=
ons&quot; feature should <br>
&gt; &gt;&gt; work this way.<br>
&gt; &gt;<br>
&gt; &gt; Yes, I was thinking the same to create a pseudo schema compri=
sing of all <br>
&gt; &gt; the schema fragements &lt;types&gt;/&lt;xsd:schema&gt; in the=
 wsdl(but it is bit of <br>
&gt; &gt; a work, since those imports also need to have correct namespa=
ce etc).<br>
&gt; <br>
&gt; The &lt;xsd:import&gt;s need to have 'namespace' attribute with va=
lue of <br>
&gt; the 'targetNamespace' of the corresponding &lt;xsd:schema&gt; elem=
ent, but <br>
&gt; that's not awful lot of work, IMO.<br>
</tt><br>
<tt>If you're synthesizing schema documents to glue together the ones i=
n the WSDL then you may not even need to use &quot;honour-all-schemaLoc=
ations&quot;. Create a schema document for each namespace with &lt;xs:i=
nclude&gt;s (for each schema document in the WSDL with that target name=
space) and then combine those together with &lt;xs:import&gt;s for each=
 of those namespaces in a &quot;master&quot; schema document. That shou=
ld work with any schema processor, not just those which honour multiple=
 imports for the same namespace.</tt><br>
<tt><br>
&gt; -- <br>
&gt; Stanimir<br>
&gt; <br>
&gt; ------------------------------------------------------------------=
---<br>
&gt; To unsubscribe, e-mail: j-users-unsubscribe@xerces.apache.org<br>
&gt; For additional commands, e-mail: j-users-help@xerces.apache.org</t=
t><br>
<br>
<tt>Thanks.<br>
</tt><br>
<tt>Michael Glavassevich<br>
XML Parser Development<br>
IBM Toronto Lab<br>
E-mail: mrglavas@ca.ibm.com</tt><br>
<tt>E-mail: mrglavas@apache.org</tt></body></html>=


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic