|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.plexus.util.Expand
Unzip a file.
Field Summary | |
private java.io.File |
dest
|
private boolean |
overwrite
|
private java.io.File |
source
|
Constructor Summary | |
Expand()
|
Method Summary | |
void |
execute()
Do the work. |
protected void |
expandFile(java.io.File srcF,
java.io.File dir)
Description of the Method |
protected void |
extractFile(java.io.File srcF,
java.io.File dir,
java.io.InputStream compressedInputStream,
java.lang.String entryName,
java.util.Date entryDate,
boolean isDirectory)
Description of the Method |
java.io.File |
normalize(java.lang.String path)
"normalize" the given absolute path. |
java.io.File |
resolveFile(java.io.File file,
java.lang.String filename)
Interpret the filename as a file relative to the given file - unless the filename already represents an absolute filename. |
void |
setDest(java.io.File d)
Set the destination directory. |
void |
setOverwrite(boolean b)
Should we overwrite files in dest, even if they are newer than the corresponding entries in the archive? |
void |
setSrc(java.io.File s)
Set the path to zip-file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private java.io.File dest
private java.io.File source
private boolean overwrite
Constructor Detail |
public Expand()
Method Detail |
public void execute() throws java.lang.Exception
BuildException
- Thrown in unrecoverable error.
java.lang.Exception
protected void expandFile(java.io.File srcF, java.io.File dir)
protected void extractFile(java.io.File srcF, java.io.File dir, java.io.InputStream compressedInputStream, java.lang.String entryName, java.util.Date entryDate, boolean isDirectory) throws java.io.IOException
java.io.IOException
public void setDest(java.io.File d)
d
- Path to the directory.public void setSrc(java.io.File s)
s
- Path to zip-file.public void setOverwrite(boolean b)
public java.io.File resolveFile(java.io.File file, java.lang.String filename)
file
- the "reference" file for relative paths. This manager must
be an absolute file and must not contain "./" or
"../" sequences (same for \ instead of /). If it is null,
this call is equivalent to new java.io.File(filename)
.filename
- a file name
public java.io.File normalize(java.lang.String path)
This includes:
java.lang.NullPointerException
- if the file path is equal to null.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |