function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
GregThoenGregThoen 

Apex cannot parse wsdl

Hi,
 
I'm running into an issue where when I try to generate Apex code from WSDL, I get a message like:
 
Unsupported WSDL. Operation '[operation name]' has more than one output element
 
However,
 
The operation does not have more than one output element, so I'm not sure why it's saying this.  In fact, if I change an <all> to <sequence>, it accepts it just fine, even though clearly both <all> and <sequence> allow multiple elements underneath them.
 
Here is some specific portions of the WSDL that Apex can consume and generate code for:
 
Code:
    <xsd:element name="HeadersResponse">
      <xsd:complexType>
        <xsd:all>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="headers" type="ns1:Headers"/>
        </xsd:all>
      </xsd:complexType>
    </xsd:element>

  <wsdl:message name="GetAvailableExportHeadersResponse">
     <wsdl:part name="GetAvailableExportHeadersResponse" element="ns1:HeadersResponse"/>
  </wsdl:message>

  <wsdl:operation name="GetAvailableExportHeaders">
     <wsdl:input name="GetAvailableExportHeadersRequest" message="GetAvailableExportHeadersRequest"/>
     <wsdl:output name="GetAvailableExportHeadersResponse" message="GetAvailableExportHeadersResponse"/>
  </wsdl:operation>

 
Here is the relevant portions of the WSDL changed so that it does NOT work:
 
Code:
    <xsd:element name="HeadersResponse">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="headers" type="ns1:Headers"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

  <wsdl:message name="GetAvailableExportHeadersResponse">
     <wsdl:part name="GetAvailableExportHeadersResponse" element="ns1:HeadersResponse"/>
  </wsdl:message>

  <wsdl:operation name="GetAvailableExportHeaders">
    <wsdl:input name="GetAvailableExportHeadersRequest" message="GetAvailableExportHeadersRequest"/>
    <wsdl:output name="GetAvailableExportHeadersResponse" message="GetAvailableExportHeadersResponse"/>
  </wsdl:operation>

 
Note that the ONLY change is that I changed <xsd:all> to <xsd:sequence>.  This would seem like a bug to me, as in both cases, an example of the response XML is the same:
 
Code:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
   <soapenv:Body>
      <axis2ns1:HeadersResponse xmlns:axis2ns1="MyNS">
         <axis2ns1:status>
            <axis2ns1:statusCode>300</axis2ns1:statusCode>
            <axis2ns1:statusMsg>Available headers retreived successfully.</axis2ns1:statusMsg>
         </axis2ns1:status>
         <axis2ns1:headers>
            <axis2ns1:header>
               <axis2ns1:headerId>*ORDER ID*</axis2ns1:headerId>
            </axis2ns1:header>
         </axis2ns1:headers>
      </axis2ns1:HeadersResponse>
   </soapenv:Body>
</soapenv:Envelope>

 
Note that a) it's the same SOAP no matter which way the wsdl is defined (it's just that order of elements could potentially be changed), and b) there is only one top-level response element (HeadersResponse in this case).  I normally wouldn't care, but the problem is that I would really like to be able to use XSD extension, which requires the use of <sequence> rather than <all>.
 
Thanks in advance,
Greg
cheenathcheenath
Can you post the full WSDL? I can take a look.

Thanks,


GregThoenGregThoen

Hi,

 

Here's a stripped-down small wsdl that exhibits the apparent bug:

 

This WSDL works:

Code:
<—xml version = '1.0' encoding = 'UTF-8'–>
<wsdl:definitions
  name="TestService"
  targetNamespace="http://com/test/webservices/2"
  xmlns="http://com/test/webservices/2"
  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  xmlns:tns="http://com/test/webservices/2"
  xmlns:ns1="http://com.test.webservices/types/2">

  <wsdl:types>
<xsd:schema 
    targetNamespace="http://com.test.webservices/types/2" 
    xmlns="http://com.test.webservices/types/2" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:ns1="http://com.test.webservices/types/2"
    xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
    jaxb:version="2.0"
    elementFormDefault="qualified">


    <xsd:complexType name="Status">
      <xsd:all>
         <xsd:element name="statusCode" type="xsd:int" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="statusMsg" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="testIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="headerTypeId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="testIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
     <xsd:complexType name="Cell">
        <xsd:all>
           <xsd:element name="headerId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="value" type="xsd:string" minOccurs="0" maxOccurs="1"/>
           <xsd:element name="operator" type="xsd:string" minOccurs="0" maxOccurs="1"/>
        </xsd:all>
     </xsd:complexType>

    <!--Response Elements-->
      
    <xsd:element name="TestResponse">
      <xsd:complexType>
        <xsd:all>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/>
        </xsd:all>
      </xsd:complexType>
    </xsd:element>

    <!--Request Elements-->
    
    <xsd:element name="TestRequest">
      <xsd:complexType>
        <xsd:sequence>
          <xsd:element name="cell" type="ns1:Cell" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>
    
</xsd:schema>
  </wsdl:types>

  <wsdl:message name="TestRequest">
     <wsdl:part name="TestRequest" element="ns1:TestRequest"/>
  </wsdl:message>
  <wsdl:message name="TestResponse">
     <wsdl:part name="TestResponse" element="ns1:TestResponse"/>
  </wsdl:message>

  <wsdl:portType name="TestWSPortType">
     <wsdl:operation name="TestCall">
        <wsdl:input name="TestRequest" message="TestRequest"/>
        <wsdl:output name="TestResponse" message="TestResponse"/>
     </wsdl:operation>
  </wsdl:portType>
  
  
  <wsdl:binding name="TestWSBinding" type="tns:TestWSPortType">
     <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="TestCall">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
  </wsdl:binding>


  <wsdl:service name="TestWebService">
     <wsdl:port name="TestWSSoapPort" binding="tns:TestWSBinding">
        <soap:address location="http://localhost:8988/TestWebServices/TestWS/2"/>
     </wsdl:port>
  </wsdl:service>

</wsdl:definitions>


 

But this WSDL does NOT - it gives the error:
Error: Unsupported WSDL. Operation 'TestCall' has more than one output element.
 
Code:
<—xml version = '1.0' encoding = 'UTF-8'–>
<wsdl:definitions
  name="TestService"
  targetNamespace="http://com/test/webservices/2"
  xmlns="http://com/test/webservices/2"
  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  xmlns:tns="http://com/test/webservices/2"
  xmlns:ns1="http://com.test.webservices/types/2">

  <wsdl:types>
<xsd:schema 
    targetNamespace="http://com.test.webservices/types/2" 
    xmlns="http://com.test.webservices/types/2" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:ns1="http://com.test.webservices/types/2"
    xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
    jaxb:version="2.0"
    elementFormDefault="qualified">


    <xsd:complexType name="Status">
      <xsd:all>
         <xsd:element name="statusCode" type="xsd:int" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="statusMsg" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="testIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="headerTypeId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="testIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
     <xsd:complexType name="Cell">
        <xsd:all>
           <xsd:element name="headerId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="value" type="xsd:string" minOccurs="0" maxOccurs="1"/>
           <xsd:element name="operator" type="xsd:string" minOccurs="0" maxOccurs="1"/>
        </xsd:all>
     </xsd:complexType>

    <!--Response Elements-->
      
    <xsd:element name="TestResponse">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <!--Request Elements-->
    
    <xsd:element name="TestRequest">
      <xsd:complexType>
        <xsd:sequence>
          <xsd:element name="cell" type="ns1:Cell" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>
    
</xsd:schema>
  </wsdl:types>

  <wsdl:message name="TestRequest">
     <wsdl:part name="TestRequest" element="ns1:TestRequest"/>
  </wsdl:message>
  <wsdl:message name="TestResponse">
     <wsdl:part name="TestResponse" element="ns1:TestResponse"/>
  </wsdl:message>

  <wsdl:portType name="TestWSPortType">
     <wsdl:operation name="TestCall">
        <wsdl:input name="TestRequest" message="TestRequest"/>
        <wsdl:output name="TestResponse" message="TestResponse"/>
     </wsdl:operation>
  </wsdl:portType>
  
  
  <wsdl:binding name="TestWSBinding" type="tns:TestWSPortType">
     <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="TestCall">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
  </wsdl:binding>


  <wsdl:service name="TestWebService">
     <wsdl:port name="TestWSSoapPort" binding="tns:TestWSBinding">
        <soap:address location="http://localhost:8988/TestWebServices/TestWS/2"/>
     </wsdl:port>
  </wsdl:service>

</wsdl:definitions>

 
Note that the only difference in the two WSDL's is that the TestResponse xml element has either an "all" or a "sequence" of elements underneath it.  Both tags allow all of the nested xml elements to be contained there, the "all" and "sequence" tags just determine whether those nested xml elements are ordered or not.
 
Thanks,
Greg
cheenathcheenath
Thanks for the WSDL.  There are two problems here.

1. WSDL parser is not checking  for "all" correctly. I will file a bug for this. So please use sequence.

2. TestResponse complex type in the WSDL contains two elements. This is not supported.
Apex can only return one return type, so sfdc only supports doc/literal/wrapped style of service.

   <xsd:element name="TestResponse">
      <xsd:complexType>
        <xsd:all>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/>
        </xsd:all>
      </xsd:complexType>
    </xsd:element>

If you have control over the wsdl, please change it to use sequence and wrap the TestResponse to
a wrapper that contains status and cell. eg:

   <xsd:element name="TestResponse">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="result" type="ns1:TestCallResult" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

   <xsd:element name="TestCallResult">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>



HTHs,





GregThoenGregThoen

Thanks - that's what I needed to know.  I think it's a shame that Apex requires wrapped responses, as it just makes things more verbose for other consumers of the wsdl, but that's a different issue. :)

 

Thanks,

Greg

InfopiaInfopia
Manoj,
 
Even with the workaround, wsdl2apex isn't parsing the complex types correctly.  I've included the complete wsdl and corresponding apex classes for your review.
 
Here is the generated InfopiaWebservices.cls
 
Code:
//Generated by wsdl2apex

public class InfopiaWebservices {
    public class InfopiaWSSoapPort {
        public String endpoint_x = 'http://localhost:8988/InfopiaWebServices/InfopiaWS/2';
        private String[] ns_map_type_info = new String[]{'http://com.infopia.webservices/types/2', 'InfopiaWebservicesTypes', 'http://com/infopia/webservices/2', 'InfopiaWebservices'};
        public InfopiaWebservicesTypes.StatusesResponse AddOrUpdateLines(InfopiaWebservicesTypes.Lines lines,String masterHeaderTypeId) {
            InfopiaWebservicesTypes.AddOrUpdateLinesRequest_element request_x = new InfopiaWebservicesTypes.AddOrUpdateLinesRequest_element();
            InfopiaWebservicesTypes.StatusesResponseWrapper_element response_x;
            request_x.lines = lines;
            request_x.masterHeaderTypeId = masterHeaderTypeId;
            Map<String, InfopiaWebservicesTypes.StatusesResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.StatusesResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'AddOrUpdateLinesRequest',
              'http://com.infopia.webservices/types/2',
              'StatusesResponseWrapper',
              'InfopiaWebservicesTypes.StatusesResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.LinesResponse GetLines(InfopiaWebservicesTypes.Search search,String masterHeaderTypeId) {
            InfopiaWebservicesTypes.GetLinesRequest_element request_x = new InfopiaWebservicesTypes.GetLinesRequest_element();
            InfopiaWebservicesTypes.LinesResponseWrapper_element response_x;
            request_x.search = search;
            request_x.masterHeaderTypeId = masterHeaderTypeId;
            Map<String, InfopiaWebservicesTypes.LinesResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.LinesResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'GetLinesRequest',
              'http://com.infopia.webservices/types/2',
              'LinesResponseWrapper',
              'InfopiaWebservicesTypes.LinesResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.HeadersResponse GetAvailableImportHeaders(String masterHeaderTypeId) {
            InfopiaWebservicesTypes.GetAvailableImportHeadersRequest_element request_x = new InfopiaWebservicesTypes.GetAvailableImportHeadersRequest_element();
            InfopiaWebservicesTypes.HeadersResponseWrapper_element response_x;
            request_x.masterHeaderTypeId = masterHeaderTypeId;
            Map<String, InfopiaWebservicesTypes.HeadersResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.HeadersResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'GetAvailableImportHeadersRequest',
              'http://com.infopia.webservices/types/2',
              'HeadersResponseWrapper',
              'InfopiaWebservicesTypes.HeadersResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.BaseStatusResponse AddOrUpdateLine(InfopiaWebservicesTypes.Line line,String masterHeaderTypeId) {
            InfopiaWebservicesTypes.AddOrUpdateLineRequest_element request_x = new InfopiaWebservicesTypes.AddOrUpdateLineRequest_element();
            InfopiaWebservicesTypes.StatusResponseWrapper_element response_x;
            request_x.line = line;
            request_x.masterHeaderTypeId = masterHeaderTypeId;
            Map<String, InfopiaWebservicesTypes.StatusResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.StatusResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'AddOrUpdateLineRequest',
              'http://com.infopia.webservices/types/2',
              'StatusResponseWrapper',
              'InfopiaWebservicesTypes.StatusResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.MasterHeaderTypesResponse GetAvailableExportMasterHeaderTypes() {
            InfopiaWebservicesTypes.GetAvailableExportMasterHeaderTypesRequest_element request_x = new InfopiaWebservicesTypes.GetAvailableExportMasterHeaderTypesRequest_element();
            InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element response_x;
            Map<String, InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'GetAvailableExportMasterHeaderTypesRequest',
              'http://com.infopia.webservices/types/2',
              'MasterHeaderTypesResponseWrapper',
              'InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.MasterHeaderTypesResponse GetAvailableImportMasterHeaderTypes() {
            InfopiaWebservicesTypes.GetAvailableImportMasterHeaderTypesRequest_element request_x = new InfopiaWebservicesTypes.GetAvailableImportMasterHeaderTypesRequest_element();
            InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element response_x;
            Map<String, InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'GetAvailableImportMasterHeaderTypesRequest',
              'http://com.infopia.webservices/types/2',
              'MasterHeaderTypesResponseWrapper',
              'InfopiaWebservicesTypes.MasterHeaderTypesResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
        public InfopiaWebservicesTypes.HeadersResponse GetAvailableExportHeaders(String masterHeaderTypeId) {
            InfopiaWebservicesTypes.GetAvailableExportHeadersRequest_element request_x = new InfopiaWebservicesTypes.GetAvailableExportHeadersRequest_element();
            InfopiaWebservicesTypes.HeadersResponseWrapper_element response_x;
            request_x.masterHeaderTypeId = masterHeaderTypeId;
            Map<String, InfopiaWebservicesTypes.HeadersResponseWrapper_element> response_map_x = new Map<String, InfopiaWebservicesTypes.HeadersResponseWrapper_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              '',
              'http://com.infopia.webservices/types/2',
              'GetAvailableExportHeadersRequest',
              'http://com.infopia.webservices/types/2',
              'HeadersResponseWrapper',
              'InfopiaWebservicesTypes.HeadersResponseWrapper_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.response;
        }
    }
}

 
Could you please take a look and let us know what is going on here?
 
Thank you,
Jon
InfopiaInfopia
And here is the InfopiaWebservicesTypes.cls
 
Code:
//Generated by wsdl2apex

public class InfopiaWebservicesTypes {
    public class Status {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class Statuses {
        public InfopiaWebservicesTypes.Status[] status;
        private String[] status_type_info = new String[]{'status','http://com.infopia.webservices/types/2','Status','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'status'};
    }
    public class HeadersResponse {
        public InfopiaWebservicesTypes.Headers headers;
        private String[] headers_type_info = new String[]{'headers','http://com.infopia.webservices/types/2','Headers','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'headers'};
    }
    public class MasterHeaderTypesResponse {
        public InfopiaWebservicesTypes.MasterHeaderTypes masterHeaderTypes;
        private String[] masterHeaderTypes_type_info = new String[]{'masterHeaderTypes','http://com.infopia.webservices/types/2','MasterHeaderTypes','0','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'masterHeaderTypes'};
    }
    public class Cells {
        public InfopiaWebservicesTypes.Cell[] cell;
        private String[] cell_type_info = new String[]{'cell','http://com.infopia.webservices/types/2','Cell','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'cell'};
    }
    public class BaseRequest {
        public InfopiaWebservicesTypes.User_x user_x;
        private String[] user_x_type_info = new String[]{'user','http://com.infopia.webservices/types/2','User','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'user_x'};
    }
    public class MasterHeaderTypesResponseWrapper_element {
        public InfopiaWebservicesTypes.MasterHeaderTypesResponse response;
        private String[] response_type_info = new String[]{'response','http://com.infopia.webservices/types/2','MasterHeaderTypesResponse','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'response'};
    }
    public class MasterHeaderTypes {
        public InfopiaWebservicesTypes.MasterHeaderType[] masterHeaderType;
        private String[] masterHeaderType_type_info = new String[]{'masterHeaderType','http://com.infopia.webservices/types/2','MasterHeaderType','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'masterHeaderType'};
    }
    public class Lines {
        public InfopiaWebservicesTypes.Line[] line;
        private String[] line_type_info = new String[]{'line','http://com.infopia.webservices/types/2','Line','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'line'};
    }
    public class StatusesResponse {
        public InfopiaWebservicesTypes.Statuses statuses;
        private String[] statuses_type_info = new String[]{'statuses','http://com.infopia.webservices/types/2','Statuses','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'statuses'};
    }
    public class QueryType {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class GetLinesRequest_element {
        public InfopiaWebservicesTypes.Search search;
        public String masterHeaderTypeId;
        private String[] search_type_info = new String[]{'search','http://com.infopia.webservices/types/2','Search','1','1','false'};
        private String[] masterHeaderTypeId_type_info = new String[]{'masterHeaderTypeId','http://www.w3.org/2001/XMLSchema','string','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'search','masterHeaderTypeId'};
    }
    public class Line {
        public InfopiaWebservicesTypes.Cells cells;
        private String[] cells_type_info = new String[]{'cells','http://com.infopia.webservices/types/2','Cells','0','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'cells'};
    }
    public class LinesResponseWrapper_element {
        public InfopiaWebservicesTypes.LinesResponse response;
        private String[] response_type_info = new String[]{'response','http://com.infopia.webservices/types/2','LinesResponse','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'response'};
    }
    public class StatusResponseWrapper_element {
        public InfopiaWebservicesTypes.BaseStatusResponse response;
        private String[] response_type_info = new String[]{'response','http://com.infopia.webservices/types/2','BaseStatusResponse','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'response'};
    }
    public class GetAvailableImportHeadersRequest_element {
        public String masterHeaderTypeId;
        private String[] masterHeaderTypeId_type_info = new String[]{'masterHeaderTypeId','http://www.w3.org/2001/XMLSchema','string','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'masterHeaderTypeId'};
    }
    public class LinesResponse {
        public InfopiaWebservicesTypes.Lines lines;
        public InfopiaWebservicesTypes.Search searchRequest;
        public Integer numLines;
        public Integer estimatedNumPages;
        public Integer pageNum;
        public Integer numCells;
        public Integer queryId;
        private String[] lines_type_info = new String[]{'lines','http://com.infopia.webservices/types/2','Lines','0','1','false'};
        private String[] searchRequest_type_info = new String[]{'searchRequest','http://com.infopia.webservices/types/2','Search','1','1','false'};
        private String[] numLines_type_info = new String[]{'numLines','http://www.w3.org/2001/XMLSchema','int','1','1','false'};
        private String[] estimatedNumPages_type_info = new String[]{'estimatedNumPages','http://www.w3.org/2001/XMLSchema','int','1','1','false'};
        private String[] pageNum_type_info = new String[]{'pageNum','http://www.w3.org/2001/XMLSchema','int','1','1','false'};
        private String[] numCells_type_info = new String[]{'numCells','http://www.w3.org/2001/XMLSchema','int','1','1','false'};
        private String[] queryId_type_info = new String[]{'queryId','http://www.w3.org/2001/XMLSchema','int','0','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'lines','searchRequest','numLines','estimatedNumPages','pageNum','numCells','queryId'};
    }
    public class GetAvailableExportMasterHeaderTypesRequest_element {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class HeaderIds {
        public String[] headerTypeId;
        private String[] headerTypeId_type_info = new String[]{'headerTypeId','http://www.w3.org/2001/XMLSchema','string','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'headerTypeId'};
    }
    public class MasterHeaderType {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class Search {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class User_x {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class AddOrUpdateLinesRequest_element {
        public InfopiaWebservicesTypes.Lines lines;
        public String masterHeaderTypeId;
        private String[] lines_type_info = new String[]{'lines','http://com.infopia.webservices/types/2','Lines','1','1','false'};
        private String[] masterHeaderTypeId_type_info = new String[]{'masterHeaderTypeId','http://www.w3.org/2001/XMLSchema','string','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'lines','masterHeaderTypeId'};
    }
    public class BaseStatusResponse {
        public InfopiaWebservicesTypes.Status status;
        private String[] status_type_info = new String[]{'status','http://com.infopia.webservices/types/2','Status','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'status'};
    }
    public class Headers {
        public InfopiaWebservicesTypes.Header[] header;
        private String[] header_type_info = new String[]{'header','http://com.infopia.webservices/types/2','Header','0','-1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'header'};
    }
    public class Cell {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class GetAvailableImportMasterHeaderTypesRequest_element {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class HeadersResponseWrapper_element {
        public InfopiaWebservicesTypes.HeadersResponse response;
        private String[] response_type_info = new String[]{'response','http://com.infopia.webservices/types/2','HeadersResponse','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'response'};
    }
    public class StatusesResponseWrapper_element {
        public InfopiaWebservicesTypes.StatusesResponse response;
        private String[] response_type_info = new String[]{'response','http://com.infopia.webservices/types/2','StatusesResponse','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'response'};
    }
    public class Header {
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{};
    }
    public class AddOrUpdateLineRequest_element {
        public InfopiaWebservicesTypes.Line line;
        public String masterHeaderTypeId;
        private String[] line_type_info = new String[]{'line','http://com.infopia.webservices/types/2','Line','1','1','false'};
        private String[] masterHeaderTypeId_type_info = new String[]{'masterHeaderTypeId','http://www.w3.org/2001/XMLSchema','string','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'line','masterHeaderTypeId'};
    }
    public class GetAvailableExportHeadersRequest_element {
        public String masterHeaderTypeId;
        private String[] masterHeaderTypeId_type_info = new String[]{'masterHeaderTypeId','http://www.w3.org/2001/XMLSchema','string','1','1','false'};
        private String[] apex_schema_type_info = new String[]{'http://com.infopia.webservices/types/2','true'};
        private String[] field_order_type_info = new String[]{'masterHeaderTypeId'};
    }
}

 
InfopiaInfopia

And here is the complete wsdl used to generate the above Apex classes:

Code:
<—xml version = '1.0' encoding = 'UTF-8'–>
<wsdl:definitions
  name="InfopiaService"
  targetNamespace="http://com/infopia/webservices/2"
  xmlns="http://com/infopia/webservices/2"
  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  xmlns:tns="http://com/infopia/webservices/2"
  xmlns:ns1="http://com.infopia.webservices/types/2">

  <wsdl:types>
<xsd:schema 
    targetNamespace="http://com.infopia.webservices/types/2" 
    xmlns="http://com.infopia.webservices/types/2" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:ns1="http://com.infopia.webservices/types/2"
    elementFormDefault="qualified">


    <xsd:complexType name="User">
      <xsd:all>
         <xsd:element name="userToken" type="xsd:string" minOccurs="1" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
    <xsd:complexType name="Status">
      <xsd:all>
         <xsd:element name="statusCode" type="xsd:int" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="statusMsg" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="infopiaIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierValue" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="headerTypeId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="infopiaIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="customerIdentifierHeaderId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="callId" type="xsd:int" minOccurs="1" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
    <xsd:complexType name="Statuses">
      <xsd:sequence>
        <xsd:element name="status" type="ns1:Status" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="Headers">
      <xsd:sequence>
        <xsd:element name="header" type="ns1:Header" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="Header">
      <xsd:all>
         <xsd:element name="headerId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="headerInfo" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="isSearchable" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="isRequiredWhenAdding" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="maxInfo" type="xsd:string" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="isAlwaysIncluded" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="headerTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="isUpdateable" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
    <xsd:complexType name="MasterHeaderTypes">
      <xsd:sequence>
         <xsd:element name="masterHeaderType" type="ns1:MasterHeaderType" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:complexType name="MasterHeaderType">
      <xsd:all>
         <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="headerTypes" type="ns1:HeaderIds" minOccurs="0" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
    <xsd:complexType name="HeaderIds">
      <xsd:sequence>
         <xsd:element name="headerTypeId" type="xsd:string" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:complexType name="Cells">
      <xsd:sequence>
         <xsd:element name="cell" type="ns1:Cell" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:complexType name="QueryType">
      <xsd:choice>
        <xsd:element name="queryId" type="xsd:int"/>
        <xsd:element name="pageNum" type="xsd:int"/>
      </xsd:choice>
    </xsd:complexType>

    <xsd:complexType name="Search">
      <xsd:all>
         <xsd:element name="cellsToPopulate" type="ns1:Cells" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="searchByCells" type="ns1:Cells" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="numPerPage" type="xsd:int" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="pageInfo" type="ns1:QueryType" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="andOrType" type="xsd:string" minOccurs="1" maxOccurs="1"/>
         <xsd:element name="orderByCell" type="ns1:Cell" minOccurs="0" maxOccurs="1"/>
      </xsd:all>
    </xsd:complexType>
    
     <xsd:complexType name="Cell">
        <xsd:all>
           <xsd:element name="headerId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
           <xsd:element name="value" type="xsd:string" minOccurs="0" maxOccurs="1"/>
           <xsd:element name="operator" type="xsd:string" minOccurs="0" maxOccurs="1"/>
        </xsd:all>
     </xsd:complexType>

    <xsd:complexType name="Lines">
      <xsd:sequence>
        <xsd:element name="line" type="ns1:Line" maxOccurs="unbounded" minOccurs="0"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:complexType name="Line">
      <xsd:sequence>
         <xsd:element name="cells" type="ns1:Cells" minOccurs="0" maxOccurs="1"/>
      </xsd:sequence>
    </xsd:complexType>
    

    <!--Response Elements-->
    <xsd:complexType name="BaseStatusResponse">
      <xsd:sequence>
        <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:complexType name="LinesResponse">
      <xsd:complexContent>
        <xsd:extension base="ns1:BaseStatusResponse">
          <xsd:sequence>
            <xsd:element name="lines" type="ns1:Lines" minOccurs="0" maxOccurs="1"/>
            <xsd:element name="searchRequest" type="ns1:Search" minOccurs="1" maxOccurs="1"/>
            <xsd:element name="numLines" type="xsd:int" minOccurs="1" maxOccurs="1"/>
            <xsd:element name="estimatedNumPages" type="xsd:int" minOccurs="1" maxOccurs="1"/>
            <xsd:element name="pageNum" type="xsd:int" minOccurs="1" maxOccurs="1"/>
            <xsd:element name="numCells" type="xsd:int" minOccurs="1" maxOccurs="1"/>
            <xsd:element name="queryId" type="xsd:int" minOccurs="0" maxOccurs="1"/>
          </xsd:sequence>
        </xsd:extension>
      </xsd:complexContent>
    </xsd:complexType>
    
    <xsd:complexType name="HeadersResponse">
      <xsd:complexContent>
        <xsd:extension base="ns1:BaseStatusResponse">
          <xsd:sequence>
         <xsd:element name="headers" type="ns1:Headers"/>
          </xsd:sequence>
        </xsd:extension>
      </xsd:complexContent>
    </xsd:complexType>
      
    <xsd:complexType name="MasterHeaderTypesResponse">
      <xsd:complexContent>
        <xsd:extension base="ns1:BaseStatusResponse">
          <xsd:sequence>
            <xsd:element name="masterHeaderTypes" type="ns1:MasterHeaderTypes" maxOccurs="1" minOccurs="0"/>
          </xsd:sequence>
        </xsd:extension>
      </xsd:complexContent>
    </xsd:complexType>
    
    <xsd:complexType name="StatusesResponse" >
      <xsd:sequence>
        <xsd:element name="statuses" type="ns1:Statuses" maxOccurs="1" minOccurs="1"/>
      </xsd:sequence>
    </xsd:complexType>

    <!-- Wrapper Response Elements, b/c Salesforce requires them if we want Salesforce to be able to handle our wsdl -->
    <xsd:element name="LinesResponseWrapper">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="response" type="ns1:LinesResponse" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <xsd:element name="HeadersResponseWrapper">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="response" type="ns1:HeadersResponse" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <xsd:element name="MasterHeaderTypesResponseWrapper">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="response" type="ns1:MasterHeaderTypesResponse" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <xsd:element name="StatusResponseWrapper">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="response" type="ns1:BaseStatusResponse" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <xsd:element name="StatusesResponseWrapper">
      <xsd:complexType>
        <xsd:sequence>
           <xsd:element name="response" type="ns1:StatusesResponse" minOccurs="1" maxOccurs="1"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>

    <!--Request Elements-->
    <xsd:complexType name="BaseRequest">
      <xsd:sequence>
        <xsd:element name="user" type="ns1:User" minOccurs="1" maxOccurs="1"/>
      </xsd:sequence>
    </xsd:complexType>
    
    <xsd:element name="GetAvailableExportHeadersRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest">
            <xsd:sequence>
              <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
            </xsd:sequence>
          </xsd:extension>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="GetAvailableImportHeadersRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest">
            <xsd:sequence>
              <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
            </xsd:sequence>
          </xsd:extension>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="GetAvailableExportMasterHeaderTypesRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest"/>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="GetAvailableImportMasterHeaderTypesRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest"/>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="GetLinesRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest">
            <xsd:sequence>
          <xsd:element name="search" type="ns1:Search" minOccurs="1" maxOccurs="1"/>
          <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
            </xsd:sequence>
          </xsd:extension>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="AddOrUpdateLineRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest">
            <xsd:sequence>
              <xsd:element name="line" type="ns1:Line" minOccurs="1" maxOccurs="1"/>
              <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
            </xsd:sequence>
          </xsd:extension>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
    
    <xsd:element name="AddOrUpdateLinesRequest">
      <xsd:complexType>
        <xsd:complexContent>
          <xsd:extension base="ns1:BaseRequest">
            <xsd:sequence>
              <xsd:element name="lines" type="ns1:Lines" minOccurs="1" maxOccurs="1"/>
              <xsd:element name="masterHeaderTypeId" type="xsd:string" minOccurs="1" maxOccurs="1"/>
            </xsd:sequence>
          </xsd:extension>
        </xsd:complexContent>
      </xsd:complexType>
    </xsd:element>
</xsd:schema>


 

InfopiaInfopia

And the rest of the wsdl:

Code:
  </wsdl:types>

  <wsdl:message name="GetAvailableExportHeadersRequest">
     <wsdl:part name="GetAvailableExportHeadersRequest" element="ns1:GetAvailableExportHeadersRequest"/>
  </wsdl:message>
  <wsdl:message name="GetAvailableExportHeadersResponse">
     <wsdl:part name="GetAvailableExportHeadersResponse" element="ns1:HeadersResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="GetAvailableImportHeadersRequest">
     <wsdl:part name="GetAvailableImportHeadersRequest" element="ns1:GetAvailableImportHeadersRequest"/>
  </wsdl:message>
  <wsdl:message name="GetAvailableImportHeadersResponse">
     <wsdl:part name="GetAvailableImportHeadersResponse" element="ns1:HeadersResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="GetAvailableExportMasterHeaderTypesRequest">
     <wsdl:part name="GetAvailableExportMasterHeaderTypesRequest" element="ns1:GetAvailableExportMasterHeaderTypesRequest"/>
  </wsdl:message>
  <wsdl:message name="GetAvailableExportMasterHeaderTypesResponse">
     <wsdl:part name="GetAvailableExportMasterHeaderTypesResponse" element="ns1:MasterHeaderTypesResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="GetAvailableImportMasterHeaderTypesRequest">
     <wsdl:part name="GetAvailableImportMasterHeaderTypesRequest" element="ns1:GetAvailableImportMasterHeaderTypesRequest"/>
  </wsdl:message>
  <wsdl:message name="GetAvailableImportMasterHeaderTypesResponse">
     <wsdl:part name="GetAvailableImportMasterHeaderTypesResponse" element="ns1:MasterHeaderTypesResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="GetLinesRequest">
     <wsdl:part name="GetLinesRequest" element="ns1:GetLinesRequest"/>
  </wsdl:message>
  <wsdl:message name="GetLinesResponse">
     <wsdl:part name="GetLinesResponse" element="ns1:LinesResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="AddOrUpdateLineRequest">
     <wsdl:part name="AddOrUpdateLineRequest" element="ns1:AddOrUpdateLineRequest"/>
  </wsdl:message>
  <wsdl:message name="AddOrUpdateLineResponse">
     <wsdl:part name="AddOrUpdateLineResponse" element="ns1:StatusResponseWrapper"/>
  </wsdl:message>

  <wsdl:message name="AddOrUpdateLinesRequest">
     <wsdl:part name="AddOrUpdateLinesRequest" element="ns1:AddOrUpdateLinesRequest"/>
  </wsdl:message>
  <wsdl:message name="AddOrUpdateLinesResponse">
     <wsdl:part name="AddOrUpdateLinesResponse" element="ns1:StatusesResponseWrapper"/>
  </wsdl:message>


  <wsdl:portType name="InfopiaWSPortType">
     <wsdl:operation name="GetAvailableExportHeaders">
        <wsdl:input name="GetAvailableExportHeadersRequest" message="GetAvailableExportHeadersRequest"/>
        <wsdl:output name="GetAvailableExportHeadersResponse" message="GetAvailableExportHeadersResponse"/>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableImportHeaders">
        <wsdl:input name="GetAvailableImportHeadersRequest" message="GetAvailableImportHeadersRequest"/>
        <wsdl:output name="GetAvailableImportHeadersResponse" message="GetAvailableImportHeadersResponse"/>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableExportMasterHeaderTypes">
        <wsdl:input name="GetAvailableExportMasterHeaderTypesRequest" message="GetAvailableExportMasterHeaderTypesRequest"/>
        <wsdl:output name="GetAvailableExportMasterHeaderTypesResponse" message="GetAvailableExportMasterHeaderTypesResponse"/>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableImportMasterHeaderTypes">
        <wsdl:input name="GetAvailableImportMasterHeaderTypesRequest" message="GetAvailableImportMasterHeaderTypesRequest"/>
        <wsdl:output name="GetAvailableImportMasterHeaderTypesResponse" message="GetAvailableImportMasterHeaderTypesResponse"/>
     </wsdl:operation>
     <wsdl:operation name="GetLines">
        <wsdl:input name="GetLinesRequest" message="GetLinesRequest"/>
        <wsdl:output name="GetLinesResponse" message="GetLinesResponse"/>
     </wsdl:operation>
     <wsdl:operation name="AddOrUpdateLine">
        <wsdl:input name="AddOrUpdateLineRequest" message="AddOrUpdateLineRequest"/>
        <wsdl:output name="AddOrUpdateLineResponse" message="AddOrUpdateLineResponse"/>
     </wsdl:operation>
     <wsdl:operation name="AddOrUpdateLines">
        <wsdl:input name="AddOrUpdateLinesRequest" message="AddOrUpdateLinesRequest"/>
        <wsdl:output name="AddOrUpdateLinesResponse" message="AddOrUpdateLinesResponse"/>
     </wsdl:operation>
  </wsdl:portType>
  
  
  <wsdl:binding name="InfopiaWSBinding" type="tns:InfopiaWSPortType">
     <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="GetAvailableExportHeaders">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableImportHeaders">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableExportMasterHeaderTypes">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="GetAvailableImportMasterHeaderTypes">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="GetLines">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="AddOrUpdateLine">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="AddOrUpdateLines">
        <soap:operation soapAction=""/>
        <wsdl:input>
          <soap:body use="literal"/>
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal"/>
        </wsdl:output>
     </wsdl:operation>
  </wsdl:binding>


  <wsdl:service name="InfopiaWebService">
     <wsdl:port name="InfopiaWSSoapPort" binding="tns:InfopiaWSBinding">
        <soap:address location="http://localhost:8988/InfopiaWebServices/InfopiaWS/2"/>
     </wsdl:port>
  </wsdl:service>

</wsdl:definitions>


 

cheenathcheenath
What is the error you are getting?

You can go to the "System Log" link on the top of the page and execute the web service method.
If you set the log level to CALLOUT, you can see the request and response XML that callout sends.


InfopiaInfopia

Manoj,

The problem is that the Apex code that is being generated from the wsdl doesn't include the necessary fields to make any calls.  For example, notice that the "Search" contains cellsToPopulate, searchByCells, numPerPage, pageInfo, andOrType and orderByCell.  However, none of these show up in the Search class in the generated InfopiaWebservicesTypes.cls.

Any idea why?

Thanks,

Jon

cheenathcheenath
Sorry for the delay, I didnt see your update.

"Search" is using xsd:any and this is causing trouble with wsdl2apex.
I will file this bug. Hope this will be fixed in the next release.




cheenathcheenath
Oops, i mean to say xsd:all


InfopiaInfopia
Ok, thanks Manoj.  Please let us know when you have an ETA for these two issues.
 
Thanks,
Jon
BarryPlumBarryPlum
Hello, I'm having the same issue, where the wsdl importer is not letting me import a wsdl.

Apex generation failed.

Error message:
Error: Unsupported WSDL. Operation 'updateEntitlementLineItem' has more than one output element.

I believe this is the part of the WSDL that may be generating the error.  But it looks like what you've posted.

Code:
 <xs:complexType name="updateEntitlementLineItemDataType">
            <xs:sequence> 
               <xs:element name="entitlementIdentifier" type="tns:entitlementIdentifierType" minOccurs="1" />
                <xs:element name="lineItemData" type="tns:updateLineItemDataType" minOccurs="0" maxOccurs="unbounded"/>
                <xs:element name="maintenanceLineItemData" type="tns:updateMaintenanceLineItemDataType" minOccurs="0" maxOccurs="unbounded"/>
         <xs:element name="autoDeploy" type="xs:boolean" minOccurs="0"/>
          </xs:sequence>     
    </xs:complexType>
    
    <xs:complexType name="failedUpdateEntitlementLineItemDataType">
  <xs:sequence>   
   <xs:element name="failedData" type="tns:updateEntitlementLineItemDataType" minOccurs="0"/>
   <xs:element name="reason" type="xs:string" minOccurs="0"/>
  </xs:sequence>
 </xs:complexType>
 
 <xs:complexType name="failedUpdateEntitlementLineItemDataListType">
  <xs:sequence>   
   <xs:element name="failedData" type="tns:failedUpdateEntitlementLineItemDataType" minOccurs="0" maxOccurs="unbounded"/>
  </xs:sequence>
 </xs:complexType>
    
 <xs:complexType name="updateEntitlementLineItemRequestType">
      <xs:sequence>
       <xs:element name="lineItemData" type="tns:updateEntitlementLineItemDataType" minOccurs="1" maxOccurs="unbounded"/>
         </xs:sequence>
    </xs:complexType>
    
 <xs:complexType name="updateEntitlementLineItemResponseType">
          <xs:sequence>
              <xs:element name="statusInfo"   type="tns:StatusInfoType"/>
              <xs:element name="failedData"   type="tns:failedUpdateEntitlementLineItemDataListType" minOccurs="0" />
          </xs:sequence>
    </xs:complexType>     

 


cheenathcheenath
sfdc callout only supports doc/literal/wrapped web service. Which means, you can
only have one element for the response complex type.

HTHs,


JonJessupJonJessup
Manoj,

Any idea when this issue will be resolved? We’re release some really cool web services functionality and it would be incredible to be able to take advantage of them in Salesforce!

Thanks,
Jon

GoForceGoGoForceGo

Cheenath,

 

I assume the SOAP response has to be wrapped in an additional tag as well?

 

In your example below, in addition to modifying WSDL, the Web service implementation must be modified  so that it returns the following response. 

 

<TestResponse>

  <TestCallout>

  </TestCallout>

<TestResponse>

 

 

2. TestResponse complex type in the WSDL contains two elements. This is not supported. Apex can only return one return type, so sfdc only supports doc/literal/wrapped style of service. <xsd:element name="TestResponse"> <xsd:complexType> <xsd:all> <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/> <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/> </xsd:all> </xsd:complexType> </xsd:element> If you have control over the wsdl, please change it to use sequence and wrap the TestResponse to a wrapper that contains status and cell. eg: <xsd:element name="TestResponse"> <xsd:complexType> <xsd:sequence> <xsd:element name="result" type="ns1:TestCallResult" minOccurs="1" maxOccurs="1"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="TestCallResult"> <xsd:complexType> <xsd:sequence> <xsd:element name="status" type="ns1:Status" minOccurs="1" maxOccurs="1"/> <xsd:element name="cell" type="ns1:Cell" maxOccurs="1" minOccurs="0"/> </xsd:sequence> </xsd:complexType> </xsd:element>

 

 

 

 

osamanosaman

I am having the same error while using Fedex webservice WSDL.

 

Operation getRates has more than one output element.  Below is the partof WSDL that has getRates method. Pleae have a look and help me.

 

 

<operation name="getRates" parameterOrder="RateRequest">
            <input message="ns:RateRequest"/>
            <output message="ns:RateReply"/>
</operation>

 

xs:complexType name="RateReply">
                <xs:sequence>
                    <xs:element minOccurs="1" name="HighestSeverity" type="ns:NotificationSeverityType">
                        <xs:annotation>
                            <xs:documentation>This indicates the highest level of severity of all the notifications returned in this reply</xs:documentation>
                        </xs:annotation>
                    </xs:element>
                    <xs:element maxOccurs="unbounded" minOccurs="1" name="Notifications" type="ns:Notification">
                        <xs:annotation>
                            <xs:documentation>The descriptive data regarding the results of the submitted transaction.</xs:documentation>
                        </xs:annotation>
                    </xs:element>
                    <xs:element minOccurs="0" name="TransactionDetail" type="ns:TransactionDetail">
                        <xs:annotation>
                            <xs:documentation>Descriptive data for this customer transaction. The TransactionDetail from the request is echoed back to the caller in the corresponding reply.</xs:documentation>
                        </xs:annotation>
                    </xs:element>
                    <xs:element name="Version" type="ns:VersionId">
                        <xs:annotation>
                            <xs:documentation>Identifies the version/level of a service operation expected by a caller (in each request) and performed by the callee (in each reply).</xs:documentation>
                        </xs:annotation>
                    </xs:element>
                    <xs:element name="RateReplyDetails" type="ns:RateReplyDetail" maxOccurs="unbounded" minOccurs="0">
                        <xs:annotation>
                            <xs:documentation>Rate information which was requested.</xs:documentation>
                        </xs:annotation>
                    </xs:element>
                </xs:sequence>
            </xs:complexType>

GoForceGoGoForceGo

Your RateReply should be wrapped in another type - it will be = TestCallResult in example above.

 

You need to create another type similar to "TestResponse" above which wraps your RateReply.