[ http://jira.codehaus.org/browse/XFIRE-526?page=comments#action_84006 ] 
            
mark larman commented on XFIRE-526:
-----------------------------------

The same problem occurs with generic List/Map and it does not seem to matter 
whether the style is bare or wrapped.

The online example: 
http://xfire.codehaus.org/JAXB+2.0#JAXB2.0-CodeFirstDevelopment

Does not work due to this bug as the BookService has a method

    public Book[] getBooks();

So in wsdl the returned object is declared to be of type ArrayOfBook but this 
complex type is not declared.


> Invalid wsdl for array parameters with JAXB 2.0 / Wrapped Style
> ---------------------------------------------------------------
>
>                 Key: XFIRE-526
>                 URL: http://jira.codehaus.org/browse/XFIRE-526
>             Project: XFire
>          Issue Type: Bug
>    Affects Versions: 1.1.1
>         Environment: XFire 1.1.1 in Apache Tomcat 5.5.7 in Winodws XP
>            Reporter: Pablo Pastorino
>         Assigned To: Dan Diephouse
>
> Hi, I'm trying to generate a wrapped style wsdl with jaxb 2.0 and i'm having
> problems with array parameters: the wrapper element references an array 
> complex type
> (for example: "ArrayOfString") but this types are not declared. in the wsdl.
> I'm testing with the following service interface 
> @WebService(name="TestService", targetNamespace="http://xml.service.test";)
> public interface TestService 
> {
>     @WebMethod(operationName = "EchoArray", action = "") 
>     public String[] echoArray(String[] array);
> }
> The implementation has the "parameterStyle" annotation
> @WebService(endpointInterface="test.service.xml.TestService", 
> serviceName="TestService")
> @SOAPBinding(style = SOAPBinding.Style.DOCUMENT,
>                         use = SOAPBinding.Use.LITERAL ,
>                         parameterStyle=SOAPBinding.ParameterStyle.WRAPPED)
> public class TestServiceImpl implements TestService
> {
>          public String[] echoArray(String[] array) {
>                   return array; 
>         }
> }
> The service.xml is the following
> <beans xmlns="http://xfire.codehaus.org/config/1.0";>
>  <bean id="testServiceImpl"
>   class="test.service.xml.TestServiceImpl">
>  </bean>
>  <service>
>   <serviceBean>#testServiceImpl</serviceBean>
>   <serviceFactory>#jaxbServiceFactory</serviceFactory>
>  </service>
>  <bean name="jaxbServiceFactory"
>   class="org.codehaus.xfire.jaxb2.JaxbServiceFactory">
>   <constructor-arg ref="xfire.transportManager" />
>  </bean>
> </beans>
> Finally, the generated wsdl is:
>   <wsdl:types>
>     <xsd:schema targetNamespace="http://xml.service.test"; 
> elementFormDefault="qualified" attributeFormDefault="qualified"> 
>       <xsd:element name="EchoArray">
>         <xsd:complexType>
>           <xsd:sequence>
>             <xsd:element name="in0" type="tns:ArrayOfString" nillable="true" 
> minOccurs="1" maxOccurs="1" /> 
>           </xsd:sequence>
>         </xsd:complexType>
>       </xsd:element>
>       <xsd:element name="EchoArrayResponse">
>         <xsd:complexType>
>           <xsd:sequence> 
>             <xsd:element name="out" type="tns:ArrayOfString" nillable="true" 
> minOccurs="1" maxOccurs="1" />
>           </xsd:sequence>
>         </xsd:complexType> 
>       </xsd:element>
>     </xsd:schema>
>   </wsdl:types>
> The type "ArrayOfString" is referenced but not declared in the wrapper 
> elements but is nto declared.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to