Ich habe versucht, eine Lösung für mein Problem zu suchen und ist nicht erfolgreich.Die Deklaration des Elements 'wsdl: definitions' konnte nicht gefunden werden.
Wenn ich versuche, meine XML-Datei mit dem XSD ich den nächsten Fehler bin immer zu überprüfen:
"cvc-elt.1: Cannot find the declaration of element 'wsdl:definitions'"
ich es mit http://www.xmlvalidation.com/index.php bin Validierung?
in anderen Validator Ich erhalte:
element definitions: Schemas validity error : Element '{ http://schemas.xmlsoap.org/wsdl/ }definitions': No matching global declaration available for the validation root.
Meine XML/WSDL-Datei ist
<?xml version='1.0' encoding='UTF-8'?><wsdl:definitions xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://com.my.company/IFBTCIBPSI" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" name="IFBTCIBPSI" targetNamespace="http://com.my.company/IFBTCIBPSI">
<wsdl:types>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://com.my.company/IFBTCIBPSI" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:QF2="urn:http://com.my.company/RSException_ARRAY" xmlns:QF1="urn:http://com.my.company/RSErrorMessage_ARRAY" xmlns:Q5="urn:com/EXCEPTION_ARRAY" xmlns:Q4="urn:com/IMOFDA" xmlns:Q3="urn:com/IMOC" xmlns:Q2="urn:com/IMIC" targetNamespace="http://com.my.company/IFBTCIBPSI">
<xsd:import namespace="urn:http://com.my.company/RSErrorMessage_ARRAY" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=RSErrorMessage_ARRAY.xsd" />
<xsd:import namespace="urn:http://com.my.company/RSException_ARRAY" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=RSException_ARRAY.xsd" />
<xsd:import namespace="urn:com/IMIC" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=IMIC.xsd" />
<xsd:import namespace="urn:com/IMOC" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=IMOC.xsd" />
<xsd:import namespace="urn:com/IMOFDA" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=IMOFDA.xsd" />
<xsd:import namespace="urn:com/EXCEPTION_ARRAY" schemaLocation="http://mycompany.com/IFBTCIBPSI?xsd=EXCEPTION_ARRAY.xsd" />
<xsd:element name="IFBTCIBP">
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="Q2:IMIC" />
<xsd:element ref="Q5:EXCEPTION_ARRAY" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="IFBTCIBPR">
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="Q3:IMOC" />
<xsd:element ref="Q4:IMOFDA" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="RSError">
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="QF1:RSErrorMessage_ARRAY" />
<xsd:element ref="QF2:RSException_ARRAY" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
</wsdl:types>
<wsdl:message name="IFBTCIBPR">
<wsdl:part element="tns:IFBTCIBPR" name="parameters">
</wsdl:part>
</wsdl:message>
<wsdl:message name="RSError">
<wsdl:part element="tns:RSError" name="fault">
</wsdl:part>
</wsdl:message>
<wsdl:message name="IFBTCIBP">
<wsdl:part element="tns:IFBTCIBP" name="parameters">
</wsdl:part>
</wsdl:message>
<wsdl:portType name="IFBTCIBPSI">
<wsdl:operation name="IFBTCIBP">
<wsdl:documentation />
<wsdl:input message="tns:IFBTCIBP">
</wsdl:input>
<wsdl:output message="tns:IFBTCIBPR">
</wsdl:output>
<wsdl:fault message="tns:RSError" name="fault">
</wsdl:fault>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="IFBTCIBPSI" type="tns:IFBTCIBPSI">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
<wsdl:operation name="IFBTCIBP">
<soap:operation soapAction="http://com.my.company/IFBTCIBPSI/IFBTCIBP" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
<wsdl:fault name="fault">
<soap:fault name="fault" use="literal" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="IFBTCIBPSI">
<wsdl:documentation />
<wsdl:port binding="tns:IFBTCIBPSI" name="IFBTCIBPSHttpS11Ep">
<soap:address location="http://mycompany.com/IFBTCIBPSI" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
meine XSD-Datei ist:
<?xml version='1.0' encoding='UTF-8'?><xsd:schema
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:com/IMIC"
targetNamespace="urn:com/IMIC">
<xsd:annotation>
<xsd:documentation>
</xsd:documentation>
</xsd:annotation>
<xsd:element name="IMIC">
<xsd:complexType>
<xsd:sequence>
<xsd:element minOccurs="1" ref="ID" />
<xsd:element minOccurs="1" ref="IT" />
<xsd:element minOccurs="1" ref="CT" />
<xsd:element minOccurs="1" ref="MI" />
<xsd:element minOccurs="1" ref="KBC" />
<xsd:element minOccurs="1" ref="TT" />
<xsd:element minOccurs="1" ref="TI" />
<xsd:element minOccurs="1" ref="CN" />
<xsd:element minOccurs="0" ref="ST" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="ID" type="xsd:date" />
<xsd:element name="IT" type="xsd:integer" />
<xsd:element name="CT" type="xsd:integer" />
<xsd:element name="MI" type="xsd:integer" />
<xsd:element name="KBC" type="xsd:integer" />
<xsd:element name="TT" type="xsd:integer" />
<xsd:element name="TI" type="xsd:string" />
<xsd:element name="CN" type="xsd:string" />
<xsd:element name="ST" type="xsd:integer" />
</xsd:schema>
Bitte Ihre Hilfe.
Vielen Dank !!
Hallo Ghislain, Vielen Dank für Ihre Antwort, können Sie mir bitte sagen/vorschlagen, wie kann ich das Problem lösen? Vielen Dank !!! – Matan
Hallo Matan, ja, ich habe meine Antwort mit spezifischen Anweisungen für xmlvalidation.com abgeschlossen (das xsi: schemaLocation ist standardisiert, also sollten andere Engines es auch verstehen). Ich hoffe das hilft. –
Hallo Ghislain! Zunächst möchte ich Ihnen für Ihre Hilfe danken. Es ist sehr geschätzt! Wir haben Ihre Lösung geprüft und die Gültigkeitsprüfung für [xmlvalidation.com] [1] unter Verwendung der bereitgestellten .dtd-Dateien bestanden. Das Problem, dass die Validierung den ** xmllint ** Linux Validator ohne zusätzliche externe Schemata/Dateien passieren sollte. Ist es möglich, die Dateien von Beispiel zu bearbeiten/zu ändern/zu vereinfachen, um die Verwendung von externen .dtd-Dateien zu vermeiden? Nochmals vielen Dank! [1]: http://xmlvalidation.com – Matan