Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [SOAP][WSDL] Problem z widocznością typu własnego, Could not find type ...
haryb
post
Post #1





Grupa: Zarejestrowani
Postów: 137
Pomógł: 0
Dołączył: 9.11.2004
Skąd: Gdańsk

Ostrzeżenie: (0%)
-----


WItam,

Mam przykładowego
WSDLa którego testuje SoupUI
Dostaje jednak bład:
Error: Could not find type 'Client2@http://schemas.xmlsoap.org/wsdl/'. Do you mean to refer to the type named Client2@typens (in api.php.xml)?

Nie wiem dlaczego on nie widzi tego typu przy definicji kolejnego ?

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <definitions name="HaryApi"
  3. xmlns="http://schemas.xmlsoap.org/wsdl/"
  4. xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  5. xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  6. xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
  7. xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
  8. xmlns:http="http://www.w3.org/2003/05/soap/bindings/HTTP/"
  9. xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl">
  10.  
  11. <types>
  12. <xsd:schema targetNamespace="typens">
  13. <xsd:import namespace="http://schemas.xmlsoap.org/wsdl/"/>
  14. <xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
  15.  
  16. <xsd:complexType name="Client2">
  17. <xsd:all>
  18. <xsd:element name="Name" type="xsd:string" minOccurs="1" />
  19. </xsd:all>
  20. </xsd:complexType>
  21.  
  22. <xsd:complexType name="Person">
  23. <xsd:all>
  24. <xsd:element name="id" type="xsd:int" minOccurs="0" maxOccurs="1" default="0" />
  25. <xsd:element name="Street" type="Client2" minOccurs="0" />
  26. </xsd:all>
  27. </xsd:complexType>
  28. </xsd:schema>
  29. </types>
  30.  
  31. <message name="AddOper">
  32. <part name="nip" type="xsd:string"/>
  33. <part name="client" type="Person"/>
  34. </message>
  35. </definitions>
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
Pyton_000
post
Post #2





Grupa: Zarejestrowani
Postów: 8 068
Pomógł: 1414
Dołączył: 26.10.2005

Ostrzeżenie: (0%)
-----


Zobacz tak:
  1. <wsdl:definitions
  2. name="HaryApi"
  3. xmlns:tns="http://twojastrona.pl/"
  4. xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  5. xmlns:s="http://www.w3.org/2001/XMLSchema"
  6. xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
  7. xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
  8. targetNamespace="http://twojastrona.pl/">
  9.  
  10. <wsdl:types>
  11. <s:schema targetNamespace="http://twojastrona.pl/">
  12. <s:complexType name="Client2">
  13. <s:all>
  14. <s:element name="Name" type="s:string" minOccurs="1" />
  15. </s:all>
  16. </s:complexType>
  17. <s:complexType name="Person">
  18. <s:all>
  19. <s:element name="id" type="s:int" minOccurs="0" maxOccurs="1" default="0" />
  20. <s:element name="Street" type="tns:Client2" minOccurs="0" />
  21. </s:all>
  22. </s:complexType>
  23. </s:schema>
  24. </s:schema>
  25. </wsdl:types>
  26.  
  27. <wsdl:message name="AddOper">
  28. <wsdl:part name="nip" type="s:string"/>
  29. <wsdl:part name="client" type="tns:Person"/>
  30. </wsdl:message>
  31. </wsdl:definitions>


Ten post edytował Pyton_000 15.02.2014, 11:18:51
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 14.10.2025 - 17:49