请稍等 ...
×

采纳答案成功!

向帮助你的同学说点啥吧!感谢那些助人为乐的人

JDK1.9及以后的版本中ExtClassLoader变成PlatFromClassLoader?

JDK1.9及以后的版本中ExtClassLoader变成PlatFromClassLoader,目的就是觉得将*.jar直接放到Ext目录下执行不安全?所以1.9直接废除了这种做法?提供了平台类加载器,为了和系统类加载器与应用类加载器之间保持设计平衡?

正在回答

1回答

翔仔 2018-12-27 00:24:24

同学好,

1.9之后ExtClassLoader更名为PlatFromClassLoader,加载lib/modules目录下的class。这个我理解只是一种规范上的变化,即要求所有Java SE平台上的类都需要保证对PlatFromClassLoader可见,应该是另外一种类型的划分。

The extension class loader has been renamed; it is now the platform class loader. All classes in the Java SE Platform are guaranteed to be visible through the platform class loader. In addition, the classes in modules that are standardized under the Java Community Process but not part of the Java SE Platform are guaranteed to be visible through the platform class loader.

Just because a class is visible through the platform class loader does not mean the class is actually defined by the platform class loader. Some classes in the Java SE Platform are defined by the platform class loader while others are defined by the bootstrap class loader. Applications should not depend on which class loader defines which platform class.


0 回复 有任何疑惑可以回复我~
问题已解决,确定采纳
还有疑问,暂不采纳
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号