gpt4 book ai didi

java - 如何删除 Netbean 6.8 中的生成源(jax-ws)?我应该根据网站地址从 WSDL 生成 WS 客户端还是从 api 生成 WS 客户端?

转载 作者:太空宇宙 更新时间:2023-11-04 07:59:59 32 4
gpt4 key购买 nike

我尝试在 Netbean 6.8 中使用 ws-import 生成 Java 类。我想重新生成 jax-ws,因为在 ebay.api.paypalapi 包中发现了一个错误(我认为该错误是由于 Paypal SOAP Api 中的 wsdl 文件造成的)。

Netbean 6.8 不允许删除生成的源(jax-ws),因此我使用基于 www.paypal.com/wsdl/PayPalSvc.wsdl 的 wsdl 重新创建了另一个 ws 文件,但它仍然无法正常工作。

希望有人告诉我如何解决这个问题。谢谢。

错误代码如下:

    20-Oct-2012 21:39:18 : Retrieving Location: http://www.paypal.com/wsdl/PayPalSvc.wsdl 

Retrieved : https://www.paypalobjects.com/wsdl/PayPalSvc.wsdl
Saved at: C:\Documents and Settings\Karen\Desktop\ShoppingCart\src\conf
\xml-resources\web-service-references\PayPalSvc\wsdl\www.paypalobjects.com\wsdl\PayPalSvc.wsdl
Retrieving Location: CoreComponentTypes.xsd
Found in document: https://www.paypalobjects.com/wsdl/PayPalSvc.wsdl

Error: An I/O error occured. Remote host closed connection during handshake
Retrieving Location: eBLBaseComponents.xsd
Found in document: https://www.paypalobjects.com/wsdl/PayPalSvc.wsdl
Retrieved : https://www.paypalobjects.com/wsdl/eBLBaseComponents.xsd
Saved at: C:\Documents and Settings\Karen\Desktop\ShoppingCart\src\conf \xml-resources\web-service- references\PayPalSvc\wsdl\www.paypalobjects.com\wsdl\eBLBaseComponents.xsd
Retrieving Location: EnhancedDataTypes.xsd
Found in document: https://www.paypalobjects.com/wsdl/PayPalSvc.wsdl
Retrieved : https://www.paypalobjects.com/wsdl/EnhancedDataTypes.xsd
Saved at: C:\Documents and Settings\Karen\Desktop\ShoppingCart\src\conf\xml-resources\web-service- references\PayPalSvc\wsdl\www.paypalobjects.com\wsdl\EnhancedDataTypes.xsd
Retrieving Location: CoreComponentTypes.xsd
Found in document: https://www.paypalobjects.com/wsdl/eBLBaseComponents.xsd
Retrieved : https://www.paypalobjects.com/wsdl/CoreComponentTypes.xsd
Saved at: C:\Documents and Settings\Karen\Desktop\ShoppingCart\src\conf \xml-resources\web-service- references\PayPalSvc\wsdl\www.paypalobjects.com\wsdl\CoreComponentTypes.xsd
Retrieving Location: EnhancedDataTypes.xsd
Found in document: https://www.paypalobjects.com/wsdl/eBLBaseComponents.xsd
File name already exists with the same content length. Ignoring the file.:
Retrieving Location: EnhancedDataTypes.xsd
Found in document: https://www.paypalobjects.com/wsdl/eBLBaseComponents.xsd
Retrieving Location: eBLBaseComponents.xsd
Found in document: https://www.paypalobjects.com/wsdl/CoreComponentTypes.xsd
File name already exists with the same content length. Ignoring the file.:
Retrieving Location: eBLBaseComponents.xsd
Found in document: https://www.paypalobjects.com/wsdl/CoreComponentTypes.xsd`

最佳答案

wsimport可以自己手动使用。

尝试下载 wsdl 文件以及 wsdl 文件中链接的所有 xsd 文件。将 wsdl 文件另存为 .xml,将 xsd 文件另存为 .xsd 文件。修改wsdl文件以指向本地xsd文件。

然后尝试使用以下命令运行 wsimport:-

wsimport -keep -verbose -s 。 -d。 -wsdllocation

然后尝试调试。

关于java - 如何删除 Netbean 6.8 中的生成源(jax-ws)?我应该根据网站地址从 WSDL 生成 WS 客户端还是从 api 生成 WS 客户端?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12995312/

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com