public class PluginClassLoader extends URLClassLoader
| Constructor and Description |
|---|
PluginClassLoader(@NotNull JavaPluginLoader loader,
@Nullable ClassLoader parent,
@NotNull PluginDescriptionFile description,
@NotNull File dataFolder,
@NotNull File file,
@Nullable ClassLoader libraryLoader) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected Class<?> |
findClass(String name) |
JavaPlugin |
getPlugin() |
URL |
getResource(String name) |
Enumeration<URL> |
getResources(String name) |
protected Class<?> |
loadClass(String name,
boolean resolve) |
String |
toString() |
protected byte[] |
transformBytecode(byte[] bytecode) |
addURL, definePackage, findResource, findResources, getPermissions, getResourceAsStream, getURLs, newInstance, newInstancedefineClass, defineClassclearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSignerspublic PluginClassLoader(@NotNull @NotNull JavaPluginLoader loader, @Nullable @Nullable ClassLoader parent, @NotNull @NotNull PluginDescriptionFile description, @NotNull @NotNull File dataFolder, @NotNull @NotNull File file, @Nullable @Nullable ClassLoader libraryLoader) throws IOException, InvalidPluginException, MalformedURLException
public JavaPlugin getPlugin()
public URL getResource(String name)
getResource in class ClassLoaderpublic Enumeration<URL> getResources(String name) throws IOException
getResources in class ClassLoaderIOExceptionprotected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
loadClass in class ClassLoaderClassNotFoundExceptionprotected Class<?> findClass(String name) throws ClassNotFoundException
findClass in class URLClassLoaderClassNotFoundExceptionprotected byte[] transformBytecode(byte[] bytecode)
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class URLClassLoaderIOExceptionCopyright © 2021. All rights reserved.