java 找不到jar怎麼辦?找不到jar套件的解決方法
1.右鍵項目-》屬性-》Java bulid path-》jre System Library-》access rules-」resolution選擇accessible,下面填上** 點擊確定即可! ! !
推薦教學:《java學習》
2.在MyEclipse中寫Java程式碼時,用到了某個jar,import sun.misc.BASE64Decoder.*;可是MyEclipse提示:
Access restriction: The type *Decoder is not accessible due to restriction on required library C:\Program files\java\jre7\lib\rt.jar Access restriction : The constructor *BASE64Decoder() is not accessible due to restriction on required library C:\Program files\java\jre7\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
以上是java 找不到jar怎麼辦的詳細內容。更多資訊請關注PHP中文網其他相關文章!