Package org.eclipse.jetty.toolchain.test
Class JAR
java.lang.Object
org.eclipse.jetty.toolchain.test.JAR
Basic functions for working with JAR files in test cases.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Close a JAR file.static void
Create a JAR file out of the contents of a specific directory (recursively)private static void
packDir
(File baseDir, File srcDir, JarOutputStream jarout) static void
Unpack JAR file into destination directory.private static void
-
Constructor Details
-
JAR
private JAR()
-
-
Method Details
-
unpack
Unpack JAR file into destination directory.- Parameters:
jarFile
- the jar file to unpackdestDir
- the destination directory to unpack into- Throws:
IOException
- if unable to unpack jar file.
-
unpack
- Throws:
IOException
-
close
Close a JAR file.- Parameters:
jar
- the JarFile to close
-
create
Create a JAR file out of the contents of a specific directory (recursively)- Parameters:
srcDir
- the source directoryjarFile
- the destination jar file to create- Throws:
IOException
- if unable to create the jar file, or read the source directory
-
packDir
- Throws:
IOException
-