Returns a ClassPath representing all classes and resources loadable from classloader and its parent class loaders. Warning: Currently only URLClassLoader and only file:// urls are supported. @throws IOException if the attempt to read class path resources (
(ClassLoader classloader)
| 95 | |
| 96 | |
| 97 | public static ClassPath from(ClassLoader classloader) throws IOException { |
| 98 | DefaultScanner scanner = new DefaultScanner(); |
| 99 | scanner.scan(classloader); |
| 100 | return new ClassPath(scanner.getResources()); |
| 101 | } |
| 102 | |
| 103 | /** |
| 104 | * Returns all resources loadable from the current class path, including the class files of all |
nothing calls this directly
no test coverage detected