| 构造器和说明 |
|---|
ClassUtils() |
| 限定符和类型 | 方法和说明 |
|---|---|
static ClassLoader |
getDefaultClassLoader()
Return the default ClassLoader to use: typically the thread context
ClassLoader, if available; the ClassLoader that loaded the ClassUtils class
will be used as fallback.
|
public static ClassLoader getDefaultClassLoader()
Call this method if you intend to use the thread context ClassLoader in a
scenario where you clearly prefer a non-null ClassLoader reference: for
example, for class path resource loading (but not necessarily for
Class.forName, which accepts a null ClassLoader reference as
well).
null if even the system
ClassLoader isn't accessible)Thread.getContextClassLoader(),
ClassLoader.getSystemClassLoader()Copyright © 2022 10MG. All rights reserved.