类 JarUrlClassLoader
java.lang.Object
java.lang.ClassLoader
java.security.SecureClassLoader
java.net.URLClassLoader
org.springframework.boot.loader.net.protocol.jar.JarUrlClassLoader
- 所有已实现的接口:
Closeable,AutoCloseable
- 直接已知子类:
LaunchedClassLoader
URLClassLoader with optimized support for Jar URLs.- 从以下版本开始:
- 3.2.0
- 作者:
- Phillip Webb, Andy Wilkinson
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明voidClear any caches.voidclose()protected final voiddefinePackageIfNecessary(String className) Define a package before afindClasscall is made.findResource(String name) findResources(String name) protected Class<?> 从类继承的方法 java.net.URLClassLoader
addURL, definePackage, findClass, getPermissions, getResourceAsStream, getURLs, newInstance, newInstance从类继承的方法 java.security.SecureClassLoader
defineClass, defineClass从类继承的方法 java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findSystemClass, getClassLoadingLock, getDefinedPackage, getDefinedPackages, getName, getPackage, getPackages, getParent, getPlatformClassLoader, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, getUnnamedModule, isRegisteredAsParallelCapable, loadClass, registerAsParallelCapable, resolveClass, resources, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
-
构造器详细资料
-
JarUrlClassLoader
Create a newLaunchedClassLoaderinstance.- 参数:
urls- the URLs from which to load classes and resourcesparent- the parent class loader for delegation
-
-
方法详细资料
-
findResource
- 覆盖:
findResource在类中URLClassLoader
-
findResources
- 覆盖:
findResources在类中URLClassLoader- 抛出:
IOException
-
loadClass
- 覆盖:
loadClass在类中ClassLoader- 抛出:
ClassNotFoundException
-
definePackageIfNecessary
Define a package before afindClasscall is made. This is necessary to ensure that the appropriate manifest for nested JARs is associated with the package.- 参数:
className- the class name being found
-
clearCache
public void clearCache()Clear any caches. This method is called reflectively byClearCachesApplicationListener. -
close
- 指定者:
close在接口中AutoCloseable- 指定者:
close在接口中Closeable- 覆盖:
close在类中URLClassLoader- 抛出:
IOException
-