in src/main/java/org/apache/sling/commons/classloader/impl/ClassLoaderFacade.java [106:125]
public Enumeration<URL> getResources(String name) throws IOException {
if(!checkManagerActive()) {
return Collections.enumeration(EMPTY_LIST);
}
final ClassLoader[] loaders = manager.getDynamicClassLoaders();
final List<URL> resources = new ArrayList<URL>();
for(final ClassLoader cl : loaders) {
if ( cl != null ) {
try {
final Enumeration<URL> e = cl.getResources(name);
if ( e != null && e.hasMoreElements() ) {
resources.addAll(Collections.list(e));
}
} catch (Throwable t) {
logger.error("Exception while querying class loader " + cl + " for resources " + name, t);
}
}
}
return Collections.enumeration(resources);
}