public class ClassReloader extends ClassLoader
| Modifier and Type | Field and Description |
|---|---|
static long |
NO_REPEAT_MILLIS |
| Constructor and Description |
|---|
ClassReloader(String classPath) |
ClassReloader(String classPath,
ClassLoader orig)
If you want to load a class with the same name more than once, you need to use a new class loader each
time.
|
| Modifier and Type | Method and Description |
|---|---|
Class<?> |
findClass(String s) |
Class<?> |
loadClass(String s) |
static Thread |
watchLoadAndRun(String classPath,
String runnerClassName) |
static Thread |
watchLoadAndRun(String classPath,
String runnerClassName,
ClassLoader orig)
Watches the given class inside classpaths for update.
|
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSignerspublic static final long NO_REPEAT_MILLIS
public ClassReloader(String classPath)
public ClassReloader(String classPath, ClassLoader orig)
classPath - ':'-delimited list of path namesorig - fallback class loader to use when this one cannot find the class in the given classPath;
example: Thread.currentThread().getContextClassLoader()public Class<?> loadClass(String s) throws ClassNotFoundException
loadClass in class ClassLoaderClassNotFoundExceptionpublic Class<?> findClass(String s) throws ClassNotFoundException
findClass in class ClassLoaderClassNotFoundExceptionpublic static Thread watchLoadAndRun(String classPath, String runnerClassName, ClassLoader orig)
Runnable interface. The class must be an instance of
Runnable.classPath - all parts of the classpath must be on the same file systemrunnerClassName - orig - fallback class loader to use when this one cannot find the class in the given classPath;
example: Thread.currentThread().getContextClassLoader()Copyright © 2016 Github jjYBdx4IL Projects. All rights reserved.