简体   繁体   English

在Netbeans / java中添加ASMX(.net)Web服务客户端吗? 获取NullReferenceException

[英]Adding ASMX (.net) web service client in Netbeans/java? Getting NullReferenceException

Hey Folks. 嘿伙计。 I was wondering if anything special is required to add a .NET web services to the "Services" tab in NetBeans to allow my java app to consume a .NET web service. 我想知道是否需要任何特殊的操作才能将.NET Web服务添加到NetBeans的“服务”选项卡中,以允许我的Java应用程序使用.NET Web服务。

I go and add my WSDL (simple method, 1 operation, takes a string), and I continuously get a NullReferenceError as below: 我去添加我的WSDL(简单方法,1个操作,需要一个字符串),然后不断得到NullReferenceError,如下所示:

java.lang.NullPointerException
 at org.netbeans.modules.websvc.saas.model.wsdl.impl.WsdlModel.getServices(WsdlModel.java:65)
 at org.netbeans.modules.websvc.saas.wsdl.websvcmgr.WebServiceManager.addWebService(WebServiceManager.java:142)
 at org.netbeans.modules.websvc.saas.wsdl.websvcmgr.WsdlDataManagerImpl$1.run(WsdlDataManagerImpl.java:79)
 at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
[catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1957)

Is this something common? 这很常见吗?

I'm using Netbeans 6.9.1 and yes, the webservice is a stub that takes a string and displays a static message right now. 我使用的是Netbeans 6.9.1,是的,Web服务是一个存根,需要一个字符串并立即显示一条静态消息。

OK. 好。 Installing (Tools->Plugins) the SOAP web services plugin fixed my problem. 安装(工具->插件)SOAP Web服务插件解决了我的问题。 Duh! h!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM