public void createJarFile(File jar) throws IOException { if (logger.isDebugEnabled()) { logger.debug("Creating jar file " + jar + " from directory " + topLevelDirectory); } File manifest = getManifest(); if (manifest == null) { throw new IOException("No manifest found"); } FileOutputStream fileOutputStream = null; FileInputStream manifestInputStream = null; JarOutputStream jarOutputStream = null; try { fileOutputStream = new FileOutputStream(jar); manifestInputStream = new FileInputStream(manifest); jarOutputStream = new JarOutputStream(fileOutputStream, new Manifest(manifestInputStream)); addDirectory(jarOutputStream, topLevelDirectory); } finally { if (jarOutputStream != null) { jarOutputStream.close(); } else { if (fileOutputStream != null) fileOutputStream.close(); if (manifestInputStream != null) manifestInputStream.close(); } } }
public void createJarFile(File jar) throws IOException { if (log.isDebugEnabled()) { log.debug("Creating jar file " + jar + " from directory " + topLevelDirectory); } File manifest = getManifest(); if (manifest == null) { throw new IOException("No manifest found"); } FileOutputStream fileOutputStream = null; FileInputStream manifestInputStream = null; JarOutputStream jarOutputStream = null; try { fileOutputStream = new FileOutputStream(jar); manifestInputStream = new FileInputStream(manifest); jarOutputStream = new JarOutputStream(fileOutputStream, new Manifest(manifestInputStream)); addDirectory(jarOutputStream, topLevelDirectory); } finally { if (jarOutputStream != null) { jarOutputStream.close(); } else { if (fileOutputStream != null) fileOutputStream.close(); if (manifestInputStream != null) manifestInputStream.close(); } } }
public void createJarFile(File jar) throws IOException { if (log.isDebugEnabled()) { log.debug("Creating jar file " + jar + " from directory " + topLevelDirectory); } File manifest = getManifest(); if (manifest == null) { throw new IOException("No manifest found"); } FileOutputStream fileOutputStream = null; FileInputStream manifestInputStream = null; JarOutputStream jarOutputStream = null; try { fileOutputStream = new FileOutputStream(jar); manifestInputStream = new FileInputStream(manifest); jarOutputStream = new JarOutputStream(fileOutputStream, new Manifest(manifestInputStream)); addDirectory(jarOutputStream, topLevelDirectory); } finally { if (jarOutputStream != null) { jarOutputStream.close(); } else { if (fileOutputStream != null) fileOutputStream.close(); if (manifestInputStream != null) manifestInputStream.close(); } } }
String path = calculatePath(f); if (f.isFile()) { if (f.equals(getManifest())) { if (log.isDebugEnabled()) { log.debug("Skipping manifest entry " + f);
String path = calculatePath(f); if (f.isFile()) { if (f.equals(getManifest())) { if (logger.isDebugEnabled()) { logger.debug("Skipping manifest entry " + f);
String path = calculatePath(f); if (f.isFile()) { if (f.equals(getManifest())) { if (log.isDebugEnabled()) { log.debug("Skipping manifest entry " + f);