The method decodeBuffer(String) from the type CharacterDecoder is not accessible due to restriction

 The method decodeBuffer(String) from the type CharacterDecoder is not accessible due to restriction on required library C:\Program Files\Java\jdk1.6.0_43\jre\lib\rt.jar

问题的解决方式有两种:

方案1:
只需要在project build path中先移除JRE System Library,再添加库JRE System Library,重新编译后就一切正常了。
方案2:
Windows -> Preferences -> Java -> Compiler -> Errors/Warnings ->
Deprecated and trstricted API -> Forbidden reference (access rules): -> change to warning


转载处:http://blog.csdn.net/jiafu1115/article/details/6923127

你可能感兴趣的:(The method decodeBuffer(String) from the type CharacterDecoder is not accessible due to restriction)