1 Reply Latest reply on May 21, 2008 3:53 AM by Alessio Soldano

    Problem using wsprovide and @WebParam

    Joe Stevens Newbie

      I'm getting up to speed with JBossWS. I've been using wsprovide to generate wsdl files, but ran into an issue. When using the @WebParam annotation and specifying "name" and "partName", it looks like the value for "name" is ignored. For example:

      public String convert(@WebParam(name = "theName", partName = "thePartName") String input)

      Results in this message in the wsdl:

      <message name='Converter_convert'>
       <part name='thePartName' type='xsd:string'/>

      The partName is being used correctly, but what happened to the name? It's my understanding that the name attribute should be used as the name of the message. Admittedly, I'm new to this, so I might have the wrong idea. This is using JBoss AS 4.2.2GA. Can anyone clear this up? Thanks.

        • 1. Re: Problem using wsprovide and @WebParam
          Alessio Soldano Master

          From the JAX-WS specifications, section 3.6.1:

          * Conformance (Parameter naming): The javax.jws.WebParam annotation (see 7.11.4)MAY be used to
          specify the name of the wsdl:part or XML Schema element declaration corresponding to a Java parameter.
          If both the name and partName elements are used in the javax.jws.WebParam annotation then the
          partName MUST be used for the wsdl:part name attribute and the name element from the annotation
          will be ignored.