博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
java常见错误--Access restriction: The type BASE64Encoder
阅读量:7175 次
发布时间:2019-06-29

本文共 885 字,大约阅读时间需要 2 分钟。

在Eclipse中编写Java代码时,用到了BASE64Decoder,import sun.misc.BASE64Decoder;可是Eclipse提示:
Access restriction : The type BASE64Decoder is not accessible due to restriction on required library C:\Program
files\java\jre6\lib\rt.jar
Access restriction : The constructor BASE64Decoder() is not accessible due to restriction on required library C:\Program files\java\jre6\lib\rt.jar
搞 不懂是为什么,最后在http://forums.dzone.com/eclipse/384-access-restriction- problems.html找到答案,只需要在project build path中先移除JRE System Library,再添加库JRE System Library,重新编译后就一切正常了。但是我仍然很疑惑是为什么。。。
原文见:http://zhoushuyan.cn/java/the-type-base64decoder-is-not-accessible-due-to-restriction-on-required-library/
------------------------------
Windows -> Preferences -> Java -> Compiler -> Errors/Warnings ->
Deprecated and trstricted API -> Forbidden reference (access rules): -> change to warning
转自:
http://palwang.iteye.com/blog/906425

转载地址:http://khbzm.baihongyu.com/

你可能感兴趣的文章
【JAVA的 IO流之FileInputStream和FileOutputStream】
查看>>
《UNIX环境高级编程》apue.h 头文件的问题
查看>>
(转载)Http 请求处理流程
查看>>
GetVersion和GetVersionEx
查看>>
php采集利器snoopy应用技巧
查看>>
我的友情链接
查看>>
安装虚拟机shell脚本
查看>>
[Python]第一个爬虫练习
查看>>
rpm,yum,权限
查看>>
tomcat应用转到weblogic上时的问题
查看>>
vSphere 5.5 vCenter迁移至分布式交换机
查看>>
第二次作业
查看>>
viewport ——视区概念
查看>>
拓扑规则翻译函数(转)
查看>>
数据结构--图的定义和存储结构
查看>>
linux常用命令
查看>>
Appium自动化测试1 - 安装部署
查看>>
Bzoj 1648: [Usaco2006 Dec]Cow Picnic 奶牛野餐 深搜,bitset
查看>>
C# For Bot Framework
查看>>
UVa294 Divisors
查看>>