Eclipse error:Access restriction

报错:
Access restriction: The method decodeBuffer(String) from the type
CharacterDecoder is not accessible due to restriction on required library

Access restriction: The constructor BASE64Decoder() is not accessible due
to restriction on required library

Access restriction: The type
BASE64Decoder is not accessible due to restriction on required library

解决方法: 
这是eclipse设置问题,eclipse默认把这些受访问限制的API设成了ERROR,只要把 
Window-Preferences-Java
Complicer-Errors/Warnings 
里面的Deprecated and restricted
API中的Forbidden references(access rules)设置为Warning即可。

时间: 2024-10-12 06:51:45

Eclipse error:Access restriction的相关文章

Java,AWTUtilities,eclipse报编译错误:Access restriction: The type 'AWTUtilities' is not API (restriction on required library 'C:\Program Files\Java\jre7\lib\rt.jar')

[场景]调用com.sun.awt.AWTUtilities时,eclipse提示编译错误: Access restriction: The type 'AWTUtilities' is not API (restriction on required library 'C:\Program Files\Java\jre7\lib\rt.jar') [分析]eclipse项目默认的jre版本较早. com.sun.awt.AWTUtilities是在JDK 6 update10中增加的. [解决

java 错误:Access restriction: The type Resource is not accessible due to restriction on required library

Eclipse 默认把这些受访问限制的API设成了ERROR.只要把Windows-Preferences-Java-Complicer- Errors/Warnings里面的Deprecated and restricted API中的Forbidden references(access rules)选为Warning就可以编译通过. java 错误:Access restriction: The type Resource is not accessible due to restrict

Eclipse 编译错误 Access restriction:The type *** is not accessible due to restriction on... 解决方案

原文链接:http://rxxluowei.iteye.com/blog/671893. Eclipse 编译时报错:         Access restriction:The type JPEGCodec is not accessible due to restriction on required library C:/Program Files/Java/jre6/lib/rt.jar         解决方法:         Project -> Properties -> l

mysql error: Access denied for user 'root'@'localhost' (using password: YES)

昨天重装了下系统,安装好mysql后,安装了客户端工具连接mysql,提示Access denied for user 'root'@'localhost' (using password: YES) 网上找了些解决方案,都是linux系统下的解决方案 一头雾水啊 下面是 windows解决方法 1. 管理员登陆系统,停止mysql服务或者结束mysqld-nt进程2. 进入命令行,来到mysql的安装目录.假设安装目录为 C:\Program Files (x86)\MySQL\MySQL S

Access restriction: The constructor SunJCE() is not accessible due to restriction on required library(转)

错误信息: Access restriction: The constructor SunJCE() is not accessible due to restriction on required library C:\Program Files \Java\jre7\lib\ext\sunjce_provider.jar Access restriction: The type TaskTopicResolver is not accessible due to restrict 做NC的时

Access restriction: The method createJPEGEncoder(OutputStream) from the type JPEGCodec is not access

准备使用Java进行图片压缩的时候,使用 import com.sun.image.codec.jpeg.*; 结果出现错误: Access restriction: The method createJPEGEncoder(OutputStream) from the type JPEGCodec is not accessible due to restriction on required library 上网查了一下,发现是IDE的设置问题,它默认把这些受访问限制的API设成了ERROR

Access restriction required library rt.jar

在JAVA项目开发中,使用到了BASE64Decoder,但编辑运行时却会出现以下错误:Access restriction required library rt.jar,这里就详细的说明一下如何解决这个问题. 方法/步骤 双击桌面上的Eclipse快捷方式启动Eclipse.   Eclipse启动中.   选中出错的项目,点击项目菜单>属性   点击左侧的"JAVA Build Path".   切换到"Libraries"标签,选中"Acce

Access restriction: The method 'CharacterEncoder.encode(byte[])' is not API...

问题描述:Access restriction: The method 'CharacterEncoder.encode(byte[])' is not API... 解决方法:这种错误是eclipse设置问题,修改eclipse的设置即可:点击Windows --> Preferences --> Java --> Complicer --> Errors/Warnings --> Deprecated and restricted API中的Forbidden refer

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:\Program Files\Java\jre6\lib\rt.jar   解决方法: Project -> Properties -> libraries, 先remove掉JRE System Library,然后再Add Library重新加入. 将jre项目用自己下载的jre