消耗wsdl文件 [英] consuming wsdl file

查看:67
本文介绍了消耗wsdl文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

他们

Hi they

public GetStationsResponseType getStations() throws RemoteException {
	// TODO Auto-generated method stub
	if(farePortType == null)
		_initFarePortTypeProxy();
	return farePortType.getStations();
}

@Override
public GetFareResponseType getFare(GetFareRequestType parameters)
		throws RemoteException {
	if(farePortType == null)
		_initFarePortTypeProxy();
	return farePortType.getFare(parameters);
}



我正在使用代理类来重新整理响应类型的数据,上述代码似乎可以正常工作,所以我要调用此方法以通过WSDL从Web服务中检索信息.

问候

Arun



I am using proxy class to retieve data which is response type the above code does seem to work so hw to i call this method to retrieve information from the webservice via WSDL

regards

Arun

推荐答案

阿伦,

您实际上不能在WSDL文件上调用方法. WSDL仅描述了Web服务上的操作.

值得庆幸的是,它应该向您公开服务及其操作,但是您将需要构建存根或代理类以使其正常工作.

此处是较旧的文章 [
Hi Arun,

You can''t actually call methods on a WSDL file; the WSDL simply describes the operations on the web service.

Thankfully, it should expose the service and it''s operations to you, but you''ll need to build a stub or proxy class to make that work.

Here''s an older article[^] that may help you out.

Cheers.


他们

感谢您的答复,您提供的信息很有帮助.我是使用自动生成的Eclipse的存根和代理类.我试图测试我的操作,它不返回任何值.
Hi They

Thank you for the reply, the information you provided was helpful. I was stub and proxy classes using auto generated eclipse. I trying to test my operation it does not return any values.
org.apache.jasper.JasperException: An exception occurred processing JSP page /Webassign2/test2.jsp at line 25

22:    String getDest = request.getParameter("destin");
23:    farecalculator.setDestinationStation(getDest);
24:    farecalculator.setSourceStation(getsource);
25:    String getFarePortType10mtemp = sampleAreaServiceProxyid.getFare(farecalculator).getCurrency();



我在编译时遇到此错误.希望获得一些帮助.

问候

阿伦(Arun)



this error i get when i compile.Hoping for some help.

Regards

Arun


这篇关于消耗wsdl文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆