`

is not accessible due to restriction on required library

阅读更多

eclipse遇到报错:

 

The type JPEGImageEncoder is not accessible due to restriction on required library C:\Java\jre1.6.0_07\lib\rt.jar

 

google后发现用以下方式解决:

这个事eclipse的设置问题,它默认把这些受访问限制的API设成了ERROR,你只要把
Windows-Preferences-Java-Complicer-Errors/Warnings
里面的Deprecated and restricted API中的Forbidden references(access rules)选为Warning就可以编译通过了。

 

http://topic.csdn.net/u/20090716/09/a0c5c444-4ca6-43a0-b81f-6f73e426adae.html

分享到:
评论

相关推荐

    sun.misc.base64decoder.jar下载

    sun.misc.BASE64Encoder找不到jar包的解决方法?... Access restriction : The constructor BASE64Decoder() is not accessible due to restriction on required library C:\Program files\java\jre6\lib\rt.jar

    import com.sun.image.codec.jpeg.JPEGImageEncoder;包的下载

    Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library C:\Java\jre1.6.0_07\lib\rt.jar 此时解决办法: Eclipse默认把这些受访问限制的API设成了ERROR。只要...

    base64转换遇到问题解决方法

    1. Access restriction:在Eclipse中编写Java代码时,使用了BASE64Decoder,但Eclipse提示:Access restriction : The type BASE64Decoder is not accessible due to restriction on required library C:\Program ...

    eclispe错误

    在错误信息中,我们看到 "Access restriction:The type JPEGCodec is not accessible due to restriction on required library C:\Program Files\Java\jre6\lib\rt.jar",这表明你尝试访问的 `JPEGCodec` 类受到了...

    Eclipse错误解决办法

    当出现"Access restriction: Class is not accessible due to restriction on required library"错误时,这通常是因为Eclipse的访问限制规则。要解决这个问题,可以通过以下步骤将错误级别改为警告: - `Windows -...

    解决eclipse导入rt包问题

    然而,在使用Eclipse开发环境中导入这两个类时,可能会遇到访问限制错误:“Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library C:\Java\jre1.6.0_07\lib\rt...

    java识别验证码.docx

    Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library C:\Java\jre1.6.0_07\lib\rt.jar ``` **解决方案:** 1. **调整Eclipse配置**:Eclipse默认将这些受...

    Eclipse中引入com.sun.image.codec.jpeg包报错的完美解决办法

    但是,有时引入这两个包时会报出错误:`Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library C:/Java/jre1.6.0_07/lib/rt.jar`。 解决方法一:修改全局属性 ...

    Eclipse中设置jar的访问受限设置

    例如,当尝试导入一个项目时,可能会出现以下错误提示:“Access restriction: The type And is not accessible due to restriction on required library C:\Program Files (x86)\Java\jdk1.5.0_09\jre\lib\rt.jar”...

Global site tag (gtag.js) - Google Analytics