Hey Guys!

I'm stuck here trying to generate code out of my hand made wsdl file.
wsdl2java throws an exception:
[ERROR]
NullPointerException
at
org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateServic
e(WSDL11ToAxisServiceBuilder.java:246)

The wsdl file looks like this:
(services.wsdl)
<?xml version="1.0" encoding="UTF-8"?>

<wsdl:definitions  name="CalculableHouseholdService" 
        targetNamespace="http://webservice";
        xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
        xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
        xmlns:tns="http://webservice";>

        <wsdl:import namespace="http://webservice";
location="definitions/CalculableHouseholdService.wsdl"/>

        <wsdl:binding name="CalculableHouseholdServiceSoapBinding"
type="tns:CalculableHouseholdServicePortType">
                <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
                <wsdl:operation name="calculate">
                        <soap:operation soapAction="tns:calculate"/>
                        <wsdl:input>
                                <soap:body use="literal"/>
                        </wsdl:input>
                        <wsdl:output>
                                <soap:body use="literal"/>
                        </wsdl:output>
                </wsdl:operation>
                <wsdl:operation name="getInputObjects">
                        <soap:operation soapAction="tns:getInputObjects"/>
                        <wsdl:input>
                                <soap:body use="literal"/>
                        </wsdl:input>
                        <wsdl:output>
                                <soap:body use="literal"/>
                        </wsdl:output>
                </wsdl:operation>
        </wsdl:binding>

        <wsdl:service name="Calculable Household">
        <wsdl:documentation>Gets input objects from DB to the client, and
can calculate household objects </wsdl:documentation>
                <wsdl:port name="CalculabelHouseholdPort"
binding="CalculableHouseholdServiceSoapBinding">
                        <soap:address
location="http://localhost:2345/axis2/services/CalculableHouseholdServ
ice"/>
                </wsdl:port>
        </wsdl:service>
</wsdl:definitions>

(CalculableHouseholdService.wsdl)
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions name="CalculableHouseholdService" 
        targetNamespace="http://webservice";
        xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
        xmlns:tns="http://webservice";>
        
        <wsdl:import namespace="http://webservice";
location="../schemas/household.xsd" />
        
        <wsdl:message name="calculateRequest">
                <wsdl:part name="parameters" element="tns:Household"/>
        </wsdl:message>

        <wsdl:message name="calculateResponse">
                <wsdl:part name="body" element="tns:Result"/>
        </wsdl:message>

        <wsdl:message name="getInputObjectsRequest"/>
        <wsdl:message name="getInputObjectsResponse">
                <wsdl:part name="parameters" element="tns:Household"/>
        </wsdl:message>
        
        <wsdl:portType name="CalculableHouseholdServicePortType">
                <wsdl:operation name="getInputObjects">
                        <wsdl:input message="tns:getInputObjectsRequest"/>
                        <wsdl:output message="tns:getInputObjectsResponse"/>
                </wsdl:operation>
                <wsdl:operation name="calculate">
                        <wsdl:input message="tns:calculateRequest"/>
                        <wsdl:output message="tns:calculateResponse"/>
                </wsdl:operation>               
        </wsdl:portType>
</wsdl:definitions>

(Houshold.xsd)
<?xml version="1.0" encoding="UTF-8"?>

<!-- New document created at Mon Nov 12 09:50:02 CET 2007 -->

<schema targetNamespace="http://webservice";
        xmlns="http://www.w3.org/2000/10/XMLSchema";>
        <element name="Household">
                <complexType>
                        <all>
                                <element name="hid" type="positive-integer" 
min_occures="1"/>
                                <element name="memberships" type="Membership" 
nillable="true"
min_occures="0" max_occures="unbounded"/>
                        </all>
                </complexType>
        </element>
        <element name="Membership">
                <complexType>
                        <all>
                                <element name="mid" type="positive-integer" 
min_occures="1"/>
                                <element name="person" type="Person" 
nillable="true"
minOccurs="0"/>
                                <element name="first" type="date" 
nillable="true" minOccurs="0"/>
                                <element name="last" type="date" 
nillable="true" minOccurs="0"/>
                        </all>
                </complexType>
        </element>
        <element name="Person">
                <complexType>
                        <all>
                                <element name="pid" type="positive-integer" 
min_occures="1"/>
                                <element name="lastname" type="string" 
nillable="true"
minOccurs="0"/>
                                <element name="firstname" type="string" 
nillable="true"
minOccurs="0"/>
                                <element name="title" type="string" 
nillable="true"
minOccurs="0"/>
                                <element name="dateOfBirth" type="date" 
nillable="true"
minOccurs="0"/>
                                <element name="female" type="boolean" 
nillable="true"
minOccurs="0"/>
                        </all>
                </complexType>
        </element>
        <element name="Result">
                <complexType>
                        <element name="result" type="positive-integer"/>
                </complexType>
        </element>
</schema>

I just can't find the error. Maybe I've got something wrong with the
namespaces.

I would be glad for some hints!

Greets
Roman


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to