views:

43

answers:

1

Please tell me how to write wsdl file of service developed in java. For example:

package fromjava.server;

import javax.jws.WebService;
import javax.jws.WebMethod;

@WebService
public class AddNumbersImpl {

  @WebMethod(action="addnumbers")
  public int addNumbers(int number1, int number2) {
    return (number1+number2);
  }
}

this is a web service....so what will be the corresponding wsdl file? if u guys have any tutorial then please help me out.

A: 

You can use axis2's java2wsdl to generate the wsdl from a java interface. see http://ws.apache.org/axis/java/user-guide.html#Java2WSDLBuildingWSDLFromJava

Sasi
Or `wsgen` from the JDK itself
ewernli