`

解决办法:Access restriction: The type JPEGImageEncoder is not accessible due to rest

阅读更多

在Eclipse中处理图片,需要引入两个包:
import com.sun.image.codec.jpeg.JPEGCodec;
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。只要把Windows-Preferences-Java-Complicer-Errors/Warnings里面的Deprecated and restricted API中的Forbidden references(access rules)选为Warning就可以编译通过。

分享到:
评论

相关推荐

    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。只要...

    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 此时解决办法: Eclipse默认把这些受访问限制的API设成了ERROR。只要把...

    sun.misc.base64decoder.jar下载

     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 ...

    解决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.jar 解决方法就在这里

    Universal-USB-Installer

    want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is ...

    BlueToolInstall

    except where such Software is embedded in a manner not readily accessible to the end user. Licensee acknowledges that any symbols, trademarks, BASLA v1.1 5/29/02 -1- tradenames, and service marks ...

    支持32和64位的Jpcap.dll

    说明部分dll文件中有多个目录分别表示多个系统专用文件 ...Please feel free to contact the legal owner of the file regarding the copyright and the restriction in use for more information.

    TeeChart Pro Activex Control v5

    restriction to Microsoft's Visual Studio .NET. .Net fails to import indexed properties that reside at the root level of an ActiveX Control. The property has been replaced by a method of the same...

    Sortable前端框架

    unwanted touchmove events even when your finger is not moving, resulting in the sort not triggering. This option sets the minimum pointer movement that must occur before the delayed sorting is ...

    51CTO下载-DSSM335V4.part1

    Note: If the Demo does not start, be sure that the Demo Configuration Editor is not running and there are not any other demos running. If you copied the demo package directory, make sure the DSSM_335...

    A restriction of the fourier transform

    the restriction theorem

    Progress/OpenEdge语言手册

    * Wherever integer appears, this is a reference to the INTEGER or INT64 data type. * Wherever character appears, this is a reference to the CHARACTER, LONGCHAR, or CLOB data type. * Wherever ...

    php代码时间插件

    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY ...

    cJSON.rar,包含cJSON.c和cJSON.h文件

    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY...

    NGUI Next-Gen UI v3.0.6

    - FIX: Drag handles will now hide if there is not enough space to draw them. - FIX: Anchors and stretch scripts set to "run only once" will still respond to screen size changes. - FIX: Switching panel...

    hpcc-systems-ecl-ml

    the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to ...

    oracle json1.5脚本

    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY ...

    AJAX 即时通讯例子

    // "Software"), to deal in the Software without restriction, including // without limitation the rights to use, copy, modify, merge, publish, // distribute, sublicense, and/or sell copies of the ...

    unity 2018.2.10f1 Shader

    the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to ...

Global site tag (gtag.js) - Google Analytics