Java wsgen使用@WebMethod生成WSDL,但忽略@WebParam
我使用@WebService、@WebMethod和@WebParam注释从Java类生成WSDL。WSDL已生成,并包含@WebService和@WebMethod的输出,但@WebParam注释似乎被忽略 这里有一个与此问题相关的方法声明:Java wsgen使用@WebMethod生成WSDL,但忽略@WebParam,java,wsdl,wsgen,Java,Wsdl,Wsgen,我使用@WebService、@WebMethod和@WebParam注释从Java类生成WSDL。WSDL已生成,并包含@WebService和@WebMethod的输出,但@WebParam注释似乎被忽略 这里有一个与此问题相关的方法声明: @WebMethod(action = "jmsServiceInitialise") public boolean jmsServiceInitialise( @WebParam(name = "queue") String queue
@WebMethod(action = "jmsServiceInitialise")
public boolean jmsServiceInitialise(
@WebParam(name = "queue") String queueName,
@WebParam(name = "channel") String channel,
@WebParam(name = "hostname") String hostName,
@WebParam(name = "port") String port,
@WebParam(name = "requiresresponse") boolean requiresResponse) {
log.info("jmsServiceInitialise " + queueName + ": started");
// etc
return returnValue;
}
WSDL文件没有提到任何参数,但方法就在那里。该方法可以作为web服务调用,但字符串参数值均为null
我最初在Eclipse中遇到这个问题,但后来在命令行窗口JAX-WSRI 2.2.4-b01中使用wsgen复制了这个问题,并得到了相同的结果
我错过了什么
谢谢。在@WebMethod注释之后,将@WebResult注释添加到方法中
和
使@WebMethodoperationName=jmsServiceInitialise代替操作