cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Kulp (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CXF-1056) Add a constructor to generated Service class for setting only WSDL location
Date Mon, 24 Sep 2007 21:24:51 GMT

    [ https://issues.apache.org/jira/browse/CXF-1056?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12529985
] 

Daniel Kulp commented on CXF-1056:
----------------------------------


One issue MAY be the JAX-WS spec.   It specifically says:

(Section 2.7)
JAX-WS 2.0 mandates that two constructors be present on every generated service class.

It doesn't say "at least two" or say if we're allowed to add other constructors.     We'd
probably have to add the constructor and run the tck's an such to see if it will complain
about it.





> Add a constructor to generated Service class for setting only WSDL location
> ---------------------------------------------------------------------------
>
>                 Key: CXF-1056
>                 URL: https://issues.apache.org/jira/browse/CXF-1056
>             Project: CXF
>          Issue Type: Improvement
>          Components: Tooling
>    Affects Versions: 2.0.1
>         Environment: Windows XP, Maven 2.0.6
>            Reporter: Ryan Moquin
>            Priority: Minor
>
> I noticed in the generated service classes that there is only a constructor which accepts
no params and therefore uses the default WSDL and QName or one that you can pass in both and
override.  When I have a WSDL on the file system, most of the time I want to load it off the
classpath because I'll bundle it with my jar.  When the wsdl is on the filepath, wsdl2java
will generate a hardcoded filename to the WSDL, which isn't very good for portability reasons.
 It would be nice if there was a constructor to ONLY pass in a WSDL URL but use the default
QName.  I usually have to define the QName myself in the class creating the service class
so that I am able to use the constructor to override the WSDL.
> For example, part of a generated service class:
> public InventoryService(URL wsdlLocation, QName serviceName) {
>         super(wsdlLocation, serviceName);
>     }
>     public InventoryService() {
>         super(WSDL_LOCATION, SERVICE);
>     }
> Would be nice to have:
> public InventoryService(URL wsdlLocation, QName serviceName) {
>         super(wsdlLocation, serviceName);
>     }
> public InventoryService(URL wsdlLocation) {
>         super(wsdlLocation, SERVICE);
>     }
>     public InventoryService() {
>         super(WSDL_LOCATION, SERVICE);
>     }

-- 
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