You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by Kiran Bhumana <kB...@SeeBeyond.com> on 2003/01/17 20:23:00 UTC
xml external schema validator
Sorry this question might have been asked before.
I want to validate a wsdl file. And this is the file I have.
<definitions targetNamespace="urn:echo:echoService"
xmlns:tns="urn:echo:echoService"
xmlns:slt="http://schemas.xmlsoap.org/ws/2002/07/service-link/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<message name="StringMessageType">
<part name="echoString" type="xsd:string"/>
</message>
.....
</definitions>
I am using a SAX parser and have set the following,
parser.setFeature("http://xml.org/sax/features/validation"
, true);
parser.setFeature(
"http://xml.org/sax/features/namespaces",true);
parser.setFeature(
"http://apache.org/xml/features/validation/schema",true);
parser.setFeature("http://apache.org/xml/features/validation/schema-full
-checking", true);
parser.setProperty("http://apache.org/xml/properties/schema/external-sch
emaLocation", "http://schemas.xmlsoap.org/wsdl wsdl.xsd");
and it says
cvc-elt.1: Cannot find the declaration of element 'definitions'.
What is it that could be wrong ?
Thanks,
Kiran