public URI toUri(TPath path) { try { return new URI("jar:" + jarFile.toURI().toString() + "!" + path.toPathString()); } catch (URISyntaxException e) { throw new Error(e.getMessage(), e); } }
private ZipEntry entry(TPath path) { String pathString = path.toPathString(); if (pathString.startsWith("/")) { pathString = pathString.substring(1); } return file.getEntry(pathString); }
public String pathString(TPath path) { StringBuffer buffer = new StringBuffer(file.getName()); buffer.append("[").append(path.toPathString()).append("]"); return buffer.toString(); }