[ 
https://issues.apache.org/jira/browse/CXF-3662?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sergey Beryozkin resolved CXF-3662.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 2.5
                   2.4.2
         Assignee: Sergey Beryozkin

> wadl2java : Return types aren't generated properly on server interfaces for 
> methods with more than 1 response element.
> ----------------------------------------------------------------------------------------------------------------------
>
>                 Key: CXF-3662
>                 URL: https://issues.apache.org/jira/browse/CXF-3662
>             Project: CXF
>          Issue Type: Bug
>          Components: Tooling
>    Affects Versions: 2.4.1
>         Environment: Windows 7 32 bit
> java version "1.6.0_26"
> Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
> Java HotSpot(TM) Client VM (build 20.1-b02, mixed mode, sharing)
>            Reporter: Ceri Hughes
>            Assignee: Sergey Beryozkin
>             Fix For: 2.4.2, 2.5
>
>
> My wadl file frequently has more than 1 response element in the method 
> elements, i.e.:
> {code}
> <method name="GET" id="getUserDefaults">
>       <doc>Gets default user configuration values.</doc>
>       <response status="200">
>               <representation mediaType="application/xml" 
> element="fmc:userDefaults" />
>       </response>
>       <response status="400">
>               <representation mediaType="application/xml" 
> element="fmc:errorList" />
>       </response>
> </method>
> {code}
> If there is more than 1 response element, the wadl2java tool assumes that the 
> return type from generated methods is always void. There is a line of code 
> that checks for exactly 1 response element - if there isn't 1 (i.e. 0 or more 
> than 1), then void is assumed. Can it not take the representation of the 1st 
> response in a case when there is more than 1 (or better, the representation 
> from the response with a success status)?
> See the first line of 
> org.apache.cxf.jaxrs.ext.codegen.SourceGenerator.writeResponseType

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to