Package de.hsh.graja.util
Class ClassPathHacker
- java.lang.Object
-
- de.hsh.graja.util.ClassPathHacker
-
public class ClassPathHacker extends Object
-
-
Constructor Summary
Constructors Constructor Description ClassPathHacker()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
addFile(File f)
static void
addFile(String s)
static void
addFileToContextClassloader(File file)
static void
addURL(URL u)
static URLClassLoader
copyClassPathAndCreateClassLoader(List<String> classPath, Path toDir, boolean deleteOnExit)
-
-
-
Method Detail
-
addFile
public static void addFile(String s) throws IOException
- Throws:
IOException
-
addFile
public static void addFile(File f) throws IOException
- Throws:
IOException
-
addURL
public static void addURL(URL u) throws IOException
- Throws:
IOException
-
addFileToContextClassloader
public static void addFileToContextClassloader(File file) throws Exception
- Throws:
Exception
-
copyClassPathAndCreateClassLoader
public static URLClassLoader copyClassPathAndCreateClassLoader(List<String> classPath, Path toDir, boolean deleteOnExit) throws IOException
- Throws:
IOException
-
-