Eclipse导入Heritrix,报错找不到类 sun.net.www.protocol.file.FileURLConnection

来源:互联网 发布:知乎怎么按点赞数排序 编辑:程序博客网 时间:2024/06/05 20:53

eclipse导入heritrix后,发现这个唯一的错误。

原因:sun包是受保护的包,默认只有sun公司的软件才能使用。Eclipse会报错,把对保护使用waring就可以了。

具体:Windows -> Preferences -> Java -> Compiler -> Errors/Warnings-> Deprecated and trstricted API -> Forbidden reference (access rules): -> change to warning

搞定了。


欢迎访问个人博客:http://zhangxichuan.science

原创粉丝点击