|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.basedb.util.zip.TarFilePacker net.sf.basedb.util.zip.GzipFilePacker
public class GzipFilePacker
This class wraps the TarFilePacker
in a GZIP stream, creating
a tar.gz file.
Field Summary | |
---|---|
private GZIPOutputStream |
gzip
|
Constructor Summary | |
---|---|
GzipFilePacker()
Create a new packer that compresses files with the gzip format. |
Method Summary | |
---|---|
void |
close()
Finish the GZIP stream. |
String |
getDescription()
Get a short description of this file format that is suitable for display in selection list boxes. |
String |
getFileExtension()
Gets the extension that files, packed with this tool, should have, for example, zip or tar.gz Don't include the first
dot! |
String |
getMimeType()
Gets the MIME type to give compressed files from this packer |
void |
setOutputStream(OutputStream out)
Wrap the output stream in a GZIPOutputStream . |
Methods inherited from class net.sf.basedb.util.zip.TarFilePacker |
---|
pack |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private GZIPOutputStream gzip
Constructor Detail |
---|
public GzipFilePacker()
Method Detail |
---|
public String getDescription()
FilePacker
getDescription
in interface FilePacker
getDescription
in class TarFilePacker
public String getFileExtension()
FilePacker
zip
or tar.gz
Don't include the first
dot!
getFileExtension
in interface FilePacker
getFileExtension
in class TarFilePacker
public String getMimeType()
FilePacker
getMimeType
in interface FilePacker
getMimeType
in class TarFilePacker
public void setOutputStream(OutputStream out) throws IOException
GZIPOutputStream
.
setOutputStream
in interface FilePacker
setOutputStream
in class TarFilePacker
out
- The output stream to write to
IOException
- If there is an error setting the output streampublic void close() throws IOException
close
in interface FilePacker
close
in class TarFilePacker
IOException
- If there are any errors
|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |