axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Holger King (JIRA)" <>
Subject [jira] Created: (AXIS2-4607) WSDL2Java generates Java code for databindung (ADBBean) that is never reached when using custom datatypes (Map) within a WSDL
Date Tue, 19 Jan 2010 12:43:54 GMT
WSDL2Java generates Java code for databindung (ADBBean) that is never reached when using custom
datatypes (Map) within a WSDL

                 Key: AXIS2-4607
             Project: Axis2
          Issue Type: Bug
          Components: codegen
    Affects Versions: 1.5.1
         Environment: Axis2 release 1.5.1
            Reporter: Holger King
            Priority: Blocker

When having a WSDL containing a Map (referencing 0..* MapItem) datatype that is used in some
messages (here in "listObjects"):
		<schema xmlns="" targetNamespace="">
			<import namespace=""/>
			<complexType name="mapItem">
					<element name="key" nillable="true" type="xsd:anyType"/>
					<element name="value" nillable="true" type="xsd:anyType"/>
			<complexType name="Map">
					<element name="item" minOccurs="0" maxOccurs="unbounded" type="apachesoap:mapItem"/>
        <wsdl:message name="listObjectsRequest">
		<wsdl:part name="in0" type="xsd:string"/>
		<wsdl:part name="in1" type="apachesoap:Map"/>
		<wsdl:part name="in2" type="xsd:string"/>
		<wsdl:part name="in3" type="xsd:string"/>
        <wsdl:message name="listObjectsResponse">
		<wsdl:part name="listObjectsReturn" type="apachesoap:Map"/>
        <wsdl:portType name="IdentityService">
                <wsdl:operation name="listObjects" parameterOrder="in0 in1 in2 in3">
			<wsdl:input name="listObjectsRequest" message="impl:listObjectsRequest"/>
			<wsdl:output name="listObjectsResponse" message="impl:listObjectsResponse"/>

the "WSDL2JAVA" codegenerator creates following classes "" and "":

generated class "**" calls the "parse(reader)" method of the statis inner
class of the generated "":
while (!reader.isStartElement() && !reader.isEndElement());
    if (reader.isStartElement() && new javax.xml.namespace.QName("","in1").equals(reader.getName()))
}  // End of if for expected property start element

generated class "**":
if (reader.isStartElement() && new javax.xml.namespace.QName("","item").equals(reader.getName()))
    // Process the array and step past its final element's end.
    //loop until we find a start element that is not part of this array
    boolean loopDone1 = false;
    while(!loopDone1) {
        // We should be at the end element, but make sure
        while (!reader.isEndElement())
        // Step out of this element;
        // Step to next element event.
        while (!reader.isStartElement() && !reader.isEndElement())
        if (reader.isEndElement()) {
            //two continuous end elements means we are exiting the xml structure
            loopDone1 = true;
        } else {
            if (new javax.xml.namespace.QName("","item").equals(reader.getName())) {
            } else {
                loopDone1 = true;
    // call the converter utility  to convert and set the array

A SOAP-Request for "listObjects" contains the following structure:

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv=""
	xmlns:xsd="" xmlns:xsi="">
		<ns1:listObjects soapenv:encodingStyle=""
			<in0 xsi:type="xsd:string">ROLES</in0>
			<in1 href="#id0" />
			<in2 xsi:type="xsd:string">test</in2>
			<in3 xsi:type="xsd:string">test</in3>
		<multiRef id="id0" soapenc:root="0"
			xsi:type="ns2:Map" xmlns:soapenc=""
				<key xsi:type="soapenc:string">searchFilter</key>
				<value href="#id1" />
		<multiRef id="id1" soapenc:root="0"
			xsi:type="ns3:Map" xmlns:ns3=""
				<key xsi:type="soapenc:string">role</key>
				<value xsi:type="soapenc:string">*</value>

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message