cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "jimma (JIRA)" <j...@apache.org>
Subject [jira] Created: (CXF-2935) The targent namespace in @Webparam generated from a reference element in the wrapped operation is wrong
Date Wed, 11 Aug 2010 03:23:16 GMT
The targent namespace in @Webparam generated from a reference element in the wrapped operation
is wrong 
--------------------------------------------------------------------------------------------------------

                 Key: CXF-2935
                 URL: https://issues.apache.org/jira/browse/CXF-2935
             Project: CXF
          Issue Type: Bug
          Components: Tooling
            Reporter: jimma
            Assignee: jimma
             Fix For: 2.3


Pass the "-allowReferenceElement" flag and generate wrapped operation for the flowing wsdl:

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions name="WebService" targetNamespace="http://cxf.apache.org" xmlns:ns1="helloString/Name"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://cxf.apache.org" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
  <wsdl:types>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ns1="helloString/Name" xmlns:tns="http://cxf.apache.org"
attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://cxf.apache.org">
<xs:element name="helloString" type="tns:helloString"/>
  <xs:element name="helloStringResponse" type="tns:helloStringResponse"/>
  <xs:complexType name="helloString">
    <xs:sequence>
      <xs:element minOccurs="0" ref="ns1:Name"/>
    </xs:sequence>
  </xs:complexType>  
 
<xs:complexType name="helloStringResponse">
    <xs:sequence>
      <xs:element minOccurs="0" name="return" type="xs:string"/>
      <xs:element minOccurs="0" ref="ns1:Name"/>
      <xs:element minOccurs="0" name="Employee" type="tns:employee"/>
    </xs:sequence>
  </xs:complexType>
<xs:schema>
<wsdl:types>
...
</wsdl:definitions>


The  "targetNamespace" value in @WebParam annotated to "name" paramter should be "helloString/Name"
, not the default value:

The public interface WebService {
    @WebResult(name = "return", targetNamespace = "")
    @RequestWrapper(localName = "helloString", targetNamespace = "http://cxf.apache.org",
className = "org.apache.cxf.HelloString")
    @WebMethod(action = "urn:HelloString")
    @ResponseWrapper(localName = "helloString4Response", targetNamespace = "http://cxf.apache.org",
className = "org.apache.cxf.HelloStringResponse")
    public java.lang.String helloString(
        @WebParam(mode = WebParam.Mode.INOUT, name = "Name", targetNamespace = "")
        javax.xml.ws.Holder<Name> name,
        @WebParam(mode = WebParam.Mode.OUT, name = "Employee", targetNamespace = "")
        javax.xml.ws.Holder<Employee> employee
    ); 




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


Mime
View raw message