JVM学习笔记25——Launcher类源码分析
发布日期:2021-06-29 01:18:59 浏览次数:2 分类:技术文章

本文共 1094 字,大约阅读时间需要 3 分钟。

public static ClassLoader getSystemClassLoader()

Returns the system class loader for delegation. This is the default delegation parent for new ClassLoader instances, and is typically the class loader used to start the application.
This method is first invoked early in the runtime's startup sequence, at which point it creates the system class loader and sets it as the context class loader of the invoking Thread.

The default system class loader is an implementation-dependent instance of this class.

If the system property "java.system.class.loader" is defined when this method is first invoked then the value of that property is taken to be the name of a class that will be returned as the system class loader. The class is loaded using the default system class loader and must define a public constructor that takes a single parameter of type ClassLoader which is used as the delegation parent. An instance is then created using this constructor with the default system class loader as the parameter. The resulting class loader is defined to be the system class loader.

浏览源代码网站:grepcode.com

转载地址:https://blog.csdn.net/yshuoo/article/details/116540967 如侵犯您的版权,请留言回复原文章的地址,我们会给您删除此文章,给您带来不便请您谅解!

上一篇:JVM学习笔记26——自定义系统类加载器源码分析与forName方法底层剖析
下一篇:JVM学习笔记22——类加载器命名空间深度解析与实例分析

发表评论

最新留言

网站不错 人气很旺了 加油
[***.192.178.218]2024年04月26日 20时08分14秒