`
paddy.w
  • 浏览: 498249 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

eclipse中Access restriction问题的解决

阅读更多
如果在Eclipse使用某些访问受限的API时,会报这种错误:
Access restriction: The type Resource is not accessible due to restriction on required library
这是因为Eclipse默认把这些受访问限制的API设成了ERROR,在java-compiler-Errors/Warnings选项里面的Deprecated and restricted API中的Forbidden references(access rules)选为Warning就可以编译通过,只是报警告而不是报错,保证了编译能通过。
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics