@Override public String getURL(String entry) { try (ReferenceCountedJar jar = open()) { return jar.wrappedJar.getURL(entry); } catch (IOException ioe) { throw new IllegalStateException(ioe); } }
public static InputSource getInputSource(String fname, Jar jar, JspCompilationContext ctxt) throws IOException { InputSource source; if (jar != null) { String jarEntryName = fname.substring(1, fname.length()); source = new InputSource(jar.getInputStream(jarEntryName)); source.setSystemId(jar.getURL(jarEntryName)); } else { source = new InputSource(ctxt.getResourceAsStream(fname)); source.setSystemId(ctxt.getResource(fname).toExternalForm()); } return source; }
try (Jar jar = JarFactory.newInstance(jarUrl)) { if (jar.exists(jarPath)) { return new URL(jar.getURL(jarPath));
this.jspFileName = tagJar.getURL(entryName); } else { is = ctxt.getResourceAsStream(jspFileName);
} else { String entry = absFileName.substring(1); compiler.getPageInfo().addDependant(jar.getURL(entry), Long.valueOf(jar.getLastModified(entry)));
pageInfo.addDependant(jar.getURL(entryName), Long.valueOf(jar.getLastModified(entryName))); } catch (IOException ioe) {
String fragmentUrl = jar.getURL(FRAGMENT_LOCATION); InputSource source = new InputSource(fragmentUrl); source.setByteStream(is);
String fragmentUrl = jar.getURL(FRAGMENT_LOCATION); InputSource source = new InputSource(fragmentUrl); source.setByteStream(is);
wrapperUri = tagFilePath; } else { wrapperUri = tagJar.getURL(tagFilePath);