The type HttpExchange is not accessible due to restriction on required library 错误
来源:互联网 发布:国家网络信息安全举报 编辑:程序博客网 时间:2024/06/03 08:02
参考:http://stackoverflow.com/questions/860187/access-restriction-on-class-due-to-restriction-on-required-library-rt-jar
问题描述:
import com.sun.net.httpserver.HttpExchange;
报错
Access restriction: The type HttpExchange is not accessible due torestriction on required library C:\Program Files\Java\jre7\lib\rt.jar解决:
将 JRE System Library 从 Libraries 中删除,然后重新添加 JRE System Library
原因:
工程中存在多个jar中的多个class冲突,其中只有一个class是正确的class。
删除 JRE System Library 后重新添加,会让正确的class成为首选class,从而被正确找到。
(This works because you have multiple classes in different jar files. Removing and re-adding the jre lib will make the right classes be first. If you want a fundamental solution make sure you exclude the jar files with the same classes.)
0 0
- The type HttpExchange is not accessible due to restriction on required library 错误
- 错误总结:Access restriction: The type ** is not accessible due to restriction on required library
- 错误解决:The type [X] is not accessible due to restriction on required library [Y].
- The type **** is not accessible due to restriction on required library 错误
- Access restriction: The type XXX is not accessible due to restriction on required library XXX
- 解决Access restriction: The type XXXX is not accessible due to restriction on required library
- Access restriction: The type is not accessible due to restriction on required library问题处理
- Access restriction: The type XXX is not accessible due to restriction on required library XXX
- Access restriction: The type JPEGCodec is not accessible due to restriction on required library
- Access restriction: The type BASE64Encoder is not accessible due to restriction on required library
- Access restriction: The type XXXX is not accessible due to restriction on required library
- Access restriction: The type BMPImageReader is not accessible due to restriction on required library
- Access restriction: The type XXX is not accessible due to restriction on required library
- Access restriction: The type JPEGCodec is not accessible due to restriction on required library
- access restriction: The type * is not accessible due to restriction on required library
- Access restriction: The type JFrame is not accessible due to restriction on required library
- Access restriction: The type BASE64Decoder is not accessible due to restriction on required library
- Access restriction: The type XXXX is not accessible due to restriction on required library
- __attribute__ ((aligned (n), packed))
- linux线程浅析
- 【甘道夫】拷贝文件到多台服务器的Shell脚本
- 数据结构--基本概念
- sqlserver replace函数 批量替换数据库中指定字段内指定字符串参考方法
- The type HttpExchange is not accessible due to restriction on required library 错误
- HttpServletRequest request ServletRequestUtils
- 搭建高可用mongodb集群(四)—— 分片
- 关于名空间的使用小结
- Qt编程中,Ui文件如何被利用...
- Ruby on Rails: 错误“ActionController::InvalidAuthenticityToken when disable JS/Ajax request”解决方案
- hadoop 学习笔记
- 回忆录之初试三顾冒菜道
- 常量指针 和 指针常量