Access restriction: The method XXX from the type XXX is not accessible due to restriction XXX
插件重构的时候 遇到这个问题
Access restriction: The method setDefaultAutoCommit(boolean) from the type BasicDataSource is not accessible due to restriction on required library com.XXX.ro.studio.debug/lib/commons-dbcp-1.2.1.jar
开始以为是插件包之间依赖问题,但是查看一下却没有问题。
后来发现是eclipse本身设置的问题
它默认把这些受访问限制的API设成了ERROR,只要把Windows-Preferences-Java-Complicer-Errors/Warnings
里面的Deprecated and restricted API中的Forbidden references(access rules)选为Warning就可以编译通过了。
Access restriction: The method XXX from the type XXX is not accessible due to restriction XXX的更多相关文章
- Access restriction: The method typeNameToClass(String) from the type ObjectHandler is not accessible due to restriction on required library
异常: Access restriction: The method typeNameToClass(String) from the type ObjectHandler is not access ...
- Access restriction:The type JPEGCodec is not accessible due to restriction on required library C:\Program Files\Java\jre6\lib\rt.jar
解决方法: Project -> Properties -> libraries, 先remove掉JRE System Library,然后再Add Library重新加入. ===== ...
- 解决:高版本jdk编译低版本代码时eclipse提示Access restriction:The type 'Unsafe' is not accessible due to restriction on required library
在Eclipse中采用高版本jdk编译一些低版本的源码时,由于源码中使用了一些高版本中过时的API,可能就会报错,类似于: Access restriction:The type 'Unsafe' i ...
- 报错: Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library
报错: Access restriction:The type JPEGCodec is not accessible due to restriction on required library C ...
- Access restriction:The type JPEGCodec is not accessible due to restriction on required library C:\Program Files\Java\jre6\lib\rt.jar 报错
报错: Access restriction:The type JPEGCodec is not accessible due to restriction on required library C ...
- Access restriction: The type JPEGImageEncoder is not accessible due to restriction
转: 解决办法:Access restriction: The type JPEGImageEncoder is not accessible due to restriction 2011年11月2 ...
- (Error) The type AESKeyGenerator is not accessible due to restriction on required library.
error for 'Access restriction: The type AESKeyGenerator is not accessible due to restriction on requ ...
- 使用myeclipse开发java,解决java中继承JFrame类出现The type JFrame is not accessible due to restriction的问题
在java中创建窗体,导入了java中的JFrame类,之后会出现错误: Access restriction: The type QName is not accessible due to res ...
- 报错: The type ByteInputStream is not accessible due to restriction on required library
报错: Access restriction:The type JPEGCodec is not accessible due to restriction on required library C ...
- Access restriction: The type VerticalTextSpinner is not accessible due to restriction on required library........
查了下竟然是编译器报错,orz了. Access restriction: 访问限制 on required library: 在依赖库(第三方包) 那就简单了,取消限制就好, eclipse的Win ...
随机推荐
- PB程序调用C++ COM生成对象发回-2问题
C++写的COM组件用于读CPU卡,在C#中正常能够引用使用,但是在PB中却是返回-2,不识别类名,代码如下: OleObject ole_AddComole_AddCom = Create OLEO ...
- python3 web测试模块selenium
selenium是一个用于web应用程序测试工具,selenium测试直接运行在浏览器中,就像真正的用户在操作一样,支持的浏览器包括IE(7,8,9,10,11),mozilla firefox,sa ...
- Expression Tree Build
The structure of Expression Tree is a binary tree to evaluate certain expressions.All leaves of the ...
- SSH2框架搭建 和 配置文件详解
-----------补充说明----------- 文章中所列出的struts2的2.2jar包已经不是最新的了,这个版本有严重漏洞, 现在最新版本为2.3.15,所以.你懂的http://stru ...
- springboot---->集成mybatis开发(一)
这里面我们介绍一下springboot与mybatis的集成,主要完成了mybatis的真分页.一个成熟的人往往发觉可以责怪的人越来越少,人人都有他的难处. springboot简单集成mytbati ...
- MySQL 获得当前日期时间\时间戳 函数
MySQL 获得当前日期时间 函数 1.1 获得当前日期+时间(date + time)函数:now() mysql> select now(); +———————+ | now() | +—— ...
- Android: 详解触摸事件如何传递
当视图的层次结构比较复杂的时候,触摸事件的响应流程也变得复杂. 举例来说,你也许有一天想要制作一个手势极其复杂的 Activity 来折磨你的用户,你经过简单思索,认为其中应该包含一个 PageVie ...
- 2018-2019-2 《网络对抗技术》Exp0 Kali安装 Week1 20165301
2018-2019-2 <网络对抗技术>Exp0 Kali安装 Week1 20165301 安装kali 参考此网站 设置共享文件夹 虚拟机->设置->选项->共享文件 ...
- 3.操作jQuery集合《jquery实战》
3.1 创建HTML元素 使用 jquery 创建动态元素是相当容易的.可以通过 $() 函数包含一个 HTML 标签的字符串来创建. $('<div>Hello</div>' ...
- 在shell脚本中调用另一个脚本的三种不同方法(fork, exec, source)——转载
原文链接:http://blog.chinaunix.net/uid-22548820-id-3181798.html fork ( /directory/script.sh) :如果shell中包含 ...