- From: <NJayaraman@tomax.com>
- Date: Thu, 20 Sep 2001 08:41:47 -0600
- To: ht@cogsci.ed.ac.uk (Henry S. Thompson)
- Cc: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>, www-xml-schema-comments@w3.org
Hi Henry,
I am using Xerces parser for Java 1.4.3. I have Xml and XSD files in
one directory, say d:\xml. And I have my parser java code in another
directory say d:\beantest. In Xml instance document I have mentioned XSD
file with noNamespaceSchemaLocation="d:\xml\test.xsd" and in test.xsd file
I have
<xsd:include schemaLocation="schema_lib.xsd"/>. When I run java code from
d:\beantest\, it says
[Warning] :0:0: File "file:///D:/beantest/schema_lib.xsd" not found.
Could please throw some light on this?
Thanks !!
Nara
ht@cogsci.ed.a
c.uk (Henry S. To: NJayaraman@tomax.com
Thompson) cc: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>,
www-xml-schema-comments@w3.org
09/20/01 03:29 Subject: Re: Relative path in Include Element
AM
NJayaraman@tomax.com writes:
> Hi,
>
> I would like to know how to specify relative path name when
including
> other schema definitions. For eg.
>
> <?xml version="1.0" encoding="UTF-8"?>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:include schemaLocation="tmx_schema_lib.xsd"/>
The URL of the schema document should be used as the base for relative
URLs in the schemaLocation attributes of xs:include and xs:import, in
my opinion, although I don't _think_ the REC says anything about this.
Similarly, the URL of the target document should be used as the base
for relative URLs in the xsi:schemaLocation and
xsi:noNamespaceSchemaLocation attributes.
XSV behaves according to those principles.
Which validator are you using?
ht
--
Henry S. Thompson, HCRC Language Technology Group, University of
Edinburgh
W3C Fellow 1999--2001, part-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/
Received on Thursday, 20 September 2001 10:41:36 UTC