|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.openejb.util.JarExtractor
public class JarExtractor
| Field Summary | |
|---|---|
static Logger |
logger
|
| Constructor Summary | |
|---|---|
JarExtractor()
|
|
| Method Summary | |
|---|---|
static boolean |
copy(File src,
File dest)
Copy the specified file or directory to the destination. |
static boolean |
delete(File dir)
Delete the specified directory, including all of its contents and subdirectories recursively. |
static boolean |
deleteDir(File dir)
Delete the specified directory, including all of its contents and subdirectories recursively. |
static void |
extract(File file,
File destinationDir)
Extract the jar file into the specifiec destination directory. |
static File |
extract(File file,
String pathname)
Extract the Jar file into an unpacked directory structure, and return the absolute pathname to the extracted directory. |
protected static File |
extract(InputStream input,
File docBase,
String name)
Extract the specified input stream into the specified directory, creating a file named from the specified relative path. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Logger logger
| Constructor Detail |
|---|
public JarExtractor()
| Method Detail |
|---|
public static File extract(File file,
String pathname)
throws IOException
file - Jar file to unpackpathname - Context path name for web application
IllegalArgumentException - if this is not a "jar:" URL
IOException - if an input/output error was encountered
during expansion
public static void extract(File file,
File destinationDir)
throws IOException
file - jar file to unpackdestinationDir - the directory in which the jar will be unpacked; must not exist
IOException - if an input/output error was encountered during expansion
public static boolean copy(File src,
File dest)
src - File object representing the sourcedest - File object representing the destinationpublic static boolean delete(File dir)
dir - File object representing the directory to be deletedpublic static boolean deleteDir(File dir)
dir - File object representing the directory to be deleted
protected static File extract(InputStream input,
File docBase,
String name)
throws IOException
input - InputStream to be copieddocBase - Document base directory into which we are extractingname - Relative pathname of the file to be created
IOException - if an input/output error occurs
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||