【问题标题】:Using wsimport from windows - url = http://www.webservicex.net/geoipservice.asmx?WSDL从 Windows 使用 wsimport - url = http://www.webservicex.net/geoipservice.asmx?WSDL
【发布时间】:2014-07-05 06:09:58
【问题描述】:

我在使用 URL 时收到此错误

http://www.webservicex.net/geoipservice.asmx?WSDL
C:\Program Files (x86)\Java\jdk1.6.0_18\bin>wsimport **<URL>**
parsing WSDL...

[WARNING] Ignoring SOAP port "GeoIPServiceSoap12": it uses non-standard SOAP 1.2
 binding.
You must specify the "-extension" option to use this binding.
  line 197 of **<URL>**

[WARNING] ignoring port "GeoIPServiceHttpGet": no SOAP address specified. try ru
nning wsimport with -extension switch.
  line 200 of **<URL>**

[WARNING] ignoring port "GeoIPServiceHttpPost": no SOAP address specified. try r
unning wsimport with -extension switch.
  line 203 of **<URL>**
generating code...

**[ERROR] .\net\webservicex\GeoIP.java (The system cannot find the path specified)**

C:\Program Files (x86)\Java\jdk1.6.0_18\bin>

【问题讨论】:

    标签: java web-services soap wsdl wsimport


    【解决方案1】:

    此错误表明编译器需要 GeoIP.java 才能进行 - 这应该(技术上)由您的 WSDL 给出。我遇到了这个错误,这是因为我没有写入目录的权限(在这种情况下,您正在写入C:\Program Files (x86)\Java\jdk1.6.0_18\bin - 简单的测试就是尝试在此目录中运行mkdir TEST)所以无法写入 GeoIP(例如)。

    使用-d 开关指定一个目录或将您的工作目录更改为您有权限的目录。

    【讨论】:

      【解决方案2】:

      由于权限问题而出现此错误。

      C:\Program Files\Java\jdk1.8.0_65\bin> mkdir test   
      

      访问被拒绝。

      尝试使用另一个目录来放置生成的文件。

      wsimport [options] < WSDL_URL > -d <directory>
      

      指定放置生成的输出文件的位置

      E:\sei 是目录,我用来放置输出类文件。

      C:\Program Files\Java\jdk1.8.0_65\bin> wsimport -d E:\sei http://www.webservicex.net/geoipservice.asmx?wsdl
      

      【讨论】:

        【解决方案3】:

        如果http://www.webservicex.net/geoipservice.asmx?WSDL 没有响应,请改用http://wsgeoip.lavasoft.com/ipservice.asmx?WSDL

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          相关资源
          最近更新 更多