Get values from wsdl:types

View: New views
2 Messages — Rating Filter:   Alert me  

Get values from wsdl:types

by Marco-172 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I need to read the values from <wsdl:types>, but I don't find how to
do this using SOAPClient.

I have an WSDL with this types:

<wsdl:types>
    <xsd:schema targetNamespace="http://soap.domain.com/v2"
xmlns="http://www.w3.org/2001/XMLSchema">
        <simpleType name="Language">
            <restriction base="string">
                <enumeration value="EN"/>
                <enumeration value="DE"/>
                <enumeration value="ES"/>
                <enumeration value="FR"/>
                <enumeration value="GR"/>
                <enumeration value="IT"/>
                <enumeration value="PL"/>
                <enumeration value="RU"/>
            </restriction>
        </simpleType>

        <complexType name="Access">
            <sequence>
                <element name="account" type="tns:Account"/>
                <element name="subAccount" type="tns:Account" minOccurs="0"/>
                <element name="reference" type="string" minOccurs="0"/>
            </sequence>
            <attribute name="language" type="tns:Language" use="optional"/>
        </complexType>
    </xsd:schema>
</wsdl:types>

Using the "__getTypes()" function only returns something like this:

array
    0 => string 'string Language' (length=15)
    1 => string 'struct Access {
        Account account; Account subAccount;
        string reference;
        boolean testMode;
        Language language;
    }' (length=114)

Is it possible to read the "enumeration" values from the "Language"
type or must this be done using an XML Parser!?

Regards,
Marco

--
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: Get values from wsdl:types

by noddle :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello Marco,

I was looking to do the same thing. The best tool I have been able to find so far is at:

http://trac.substring.no/url/pst/browser/ (PST!)

I don't know yet how robust it is though.

Ciao,
Andrew

Marco-172 wrote:
I need to read the values from <wsdl:types>, but I don't find how to
do this using SOAPClient.

I have an WSDL with this types:

<wsdl:types>
    <xsd:schema targetNamespace="http://soap.domain.com/v2"
xmlns="http://www.w3.org/2001/XMLSchema">
        <simpleType name="Language">
            <restriction base="string">
                <enumeration value="EN"/>
                <enumeration value="DE"/>
                <enumeration value="ES"/>
                <enumeration value="FR"/>
                <enumeration value="GR"/>
                <enumeration value="IT"/>
                <enumeration value="PL"/>
                <enumeration value="RU"/>
            </restriction>
        </simpleType>

        <complexType name="Access">
            <sequence>
                <element name="account" type="tns:Account"/>
                <element name="subAccount" type="tns:Account" minOccurs="0"/>
                <element name="reference" type="string" minOccurs="0"/>
            </sequence>
            <attribute name="language" type="tns:Language" use="optional"/>
        </complexType>
    </xsd:schema>
</wsdl:types>

Using the "__getTypes()" function only returns something like this:

array
    0 => string 'string Language' (length=15)
    1 => string 'struct Access {
        Account account; Account subAccount;
        string reference;
        boolean testMode;
        Language language;
    }' (length=114)

Is it possible to read the "enumeration" values from the "Language"
type or must this be done using an XML Parser!?

Regards,
Marco

--
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php