Bug #45404 [Com]: SoapClient.__getTypes don't care about inheritance
| From: | karol dot wegner at netcall dot com | Date: | Wed, 04 Dec 2019 10:13:33 +0000 |
| Subject: | Bug #45404 [Com]: SoapClient.__getTypes don't care about inheritance | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-224058@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=45404&edit=1
ID: 45404
Comment by: karol dot wegner at netcall dot com
Reported by: oamblet at vmware dot com
Summary: SoapClient.__getTypes don't care about inheritance
Status: Open
Type: Bug
Package: SOAP related
Operating System: MacOSX 10.5
PHP Version: 5.2.6
Block user comment: N
Private report: N
New Comment:
PHP 7.2.17-0ubuntu0.18.04.1
WSDL...
<xsd:complexType xmlns:xsd='http://www.w3.org/2001/XMLSchema'
name='WSResponse'>
<xsd:sequence minOccurs='1' maxOccurs='1'>
<xsd:element name='ErrorCode' type='xsd:int' />
<xsd:element name='ErrorDescription' type='xsd:string'
minOccurs='0' />
<xsd:element name='SuccessFlag' type='xsd:boolean' />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType xmlns:xsd='http://www.w3.org/2001/XMLSchema'
name='AddressResponse'>
<xsd:complexContent>
<xsd:extension base='tns:WSResponse'>
<xsd:sequence minOccurs='1' maxOccurs='1'>
<xsd:element name='Addresses' xmlns:tns='http://webservices.netcall.com/'
type='tns:ArrayOfAddress' minOccurs='0' />
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
SoapClient::__getTypes()...
struct WSResponse {
int ErrorCode;
string ErrorDescription;
boolean SuccessFlag;
}
struct AddressResponse {
ArrayOfAddress Addresses;
}
__getTypes() AddressResponse definition does not show inherited elements from the WSResponse type it
extends (not to mention lack of minOccurs / maxOccurs)
Lack of XML schema extensions support makes the SoapClient not fit for purpose.
Previous Comments:
------------------------------------------------------------------------
[2018-07-13 15:43:26] code at joshua-behrens dot de
After debugging through the source code of the php soap extension I found the behaviour locked down
onto the namespaces. The given example from oamblet works perfectly if the posted schema has a
different targetNamespace than the wsdl.
Although the output refers the parent as a property with an underscore as name.
After reading the RFC for WSDL 2.0 I was still clueless whether this behaviour is correct. I assume
not as the WSDLs of the SOAP services I usally request share the same namespace with their schemes.
Would allowing the same namespace be correct?
------------------------------------------------------------------------
[2018-02-02 20:41:13] info at tirus dot eu
Still not working. On WIN and Linux PHP 7.1 and 7.2 i have the same problem at now
------------------------------------------------------------------------
[2017-11-16 04:24:41] chris at golfclub dot com dot au
Seeing this on php 7.1.8 on macOS 10.13.1
------------------------------------------------------------------------
[2013-03-09 12:32:32] lucky_tomov at hotmail dot com
Seeing the same bug in php 5.3.3 on Ubuntu.
------------------------------------------------------------------------
[2012-08-20 02:00:04] bkfake-php at yahoo dot com
I've just encountered this bug/shortcoming.
Thought it deserved a "bump"
the original report from 4 years ago states this bug makes it "hard".
I think the mor accurate word is "impossible"
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=45404
--
Edit this bug report at https://bugs.php.net/bug.php?id=45404&edit=1