Enumeration<URL> (@NotNull String name) { if (name.endsWith("/")) { name = name.substring(0, name.length() - 1); } if (useCache && allUrlsWereProcessed) { Loader[] loaders = cache.getLoadersByName(name); return loaders == null || loaders.length == 0 ? Collections.emptyEnumeration() : new ResourceEnumeration(name, loaders); } else { return new UncachedResourceEnumeration(name, this); } }