net.sourceforge.jaulp.file.zip
Class Zipper

java.lang.Object
  extended by net.sourceforge.jaulp.file.zip.Zipper
All Implemented Interfaces:
ZipModel

public class Zipper
extends java.lang.Object
implements ZipModel

The Class Zipper.

Version:
1.0
Author:
Asterios Raptis

Constructor Summary
Zipper(java.io.File dirToZip, java.io.File zipFile)
          Instantiates a new zipper.
Zipper(java.io.File dirToZip, java.io.File zipFile, java.io.FilenameFilter filter)
          Instantiates a new zipper.
 
Method Summary
 int getCompressionMethod()
          Returns the field compressionMethod.
 java.io.File getDirectoryToZip()
          Returns the field directoryToZip.
 java.lang.String getDirToStart()
          Returns the field dirToStart.
 int getFileCounter()
          Returns the field fileCounter.
 java.io.FilenameFilter getFileFilter()
          Returns the field fileFilter.
 long getFileLength()
          Returns the field fileLength.
 java.io.File getZipFile()
          Returns the field zipFile.
 java.lang.String getZipFileComment()
          Returns the field zipFileComment.
 java.lang.String getZipFileName()
          Returns the field zipFileName.
 java.util.zip.ZipFile getZipFileObj()
          Returns the field zipFileObj.
 int getZipLevel()
          Returns the field zipLevel.
 void setCompressionMethod(int compressionMethod)
          Sets the field compressionMethod.
 void setDirectoryToZip(java.io.File directoryToZip)
          Sets the field directoryToZip.
 void setDirToStart(java.lang.String dirToStart)
          Sets the field dirToStart.
 void setFileCounter(int fileCounter)
          Sets the field fileCounter.
 void setFileFilter(java.io.FilenameFilter fileFilter)
          Sets the field fileFilter.
 void setFileLength(long fileLength)
          Sets the field fileLength.
 void setZipFile(java.io.File zipFile)
          Sets the field zipFile.
 void setZipFileComment(java.lang.String zipFileComment)
          Sets the field zipFileComment.
 void setZipFileName(java.lang.String zipFileName)
          Sets the field zipFileName.
 void setZipFileObj(java.util.zip.ZipFile zipFileObj)
          Sets the field zipFileObj.
 void setZipLevel(int zipLevel)
          Sets the field zipLevel.
 void zip()
          Zip.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Zipper

public Zipper(java.io.File dirToZip,
              java.io.File zipFile)
Instantiates a new zipper.

Parameters:
dirToZip - the dir to zip
zipFile - the zip file

Zipper

public Zipper(java.io.File dirToZip,
              java.io.File zipFile,
              java.io.FilenameFilter filter)
Instantiates a new zipper.

Parameters:
dirToZip - the dir to zip
zipFile - the zip file
Method Detail

getCompressionMethod

public int getCompressionMethod()
Returns the field compressionMethod.

Specified by:
getCompressionMethod in interface ZipModel
Returns:
The field compressionMethod.
See Also:
ZipModel.getCompressionMethod()

getDirectoryToZip

public java.io.File getDirectoryToZip()
Returns the field directoryToZip.

Specified by:
getDirectoryToZip in interface ZipModel
Returns:
The field directoryToZip.
See Also:
ZipModel.getDirectoryToZip()

getDirToStart

public java.lang.String getDirToStart()
Returns the field dirToStart.

Specified by:
getDirToStart in interface ZipModel
Returns:
The field dirToStart.
See Also:
ZipModel.getDirToStart()

getFileCounter

public int getFileCounter()
Returns the field fileCounter.

Specified by:
getFileCounter in interface ZipModel
Returns:
The field fileCounter.
See Also:
ZipModel.getFileCounter()

getFileFilter

public java.io.FilenameFilter getFileFilter()
Returns the field fileFilter.

Specified by:
getFileFilter in interface ZipModel
Returns:
The field fileFilter.
See Also:
ZipModel.getFileFilter()

getFileLength

public long getFileLength()
Returns the field fileLength.

Specified by:
getFileLength in interface ZipModel
Returns:
The field fileLength.
See Also:
ZipModel.getFileLength()

getZipFile

public java.io.File getZipFile()
Returns the field zipFile.

Specified by:
getZipFile in interface ZipModel
Returns:
The field zipFile.
See Also:
ZipModel.getZipFile()

getZipFileComment

public java.lang.String getZipFileComment()
Returns the field zipFileComment.

Specified by:
getZipFileComment in interface ZipModel
Returns:
The field zipFileComment.
See Also:
ZipModel.getZipFileComment()

getZipFileName

public java.lang.String getZipFileName()
Returns the field zipFileName.

Specified by:
getZipFileName in interface ZipModel
Returns:
The field zipFileName.
See Also:
ZipModel.getZipFileName()

getZipFileObj

public java.util.zip.ZipFile getZipFileObj()
Returns the field zipFileObj.

Specified by:
getZipFileObj in interface ZipModel
Returns:
The field zipFileObj.

getZipLevel

public int getZipLevel()
Returns the field zipLevel.

Specified by:
getZipLevel in interface ZipModel
Returns:
The field zipLevel.
See Also:
ZipModel.getZipLevel()

setCompressionMethod

public void setCompressionMethod(int compressionMethod)
Sets the field compressionMethod.

Specified by:
setCompressionMethod in interface ZipModel
Parameters:
compressionMethod - The compressionMethod to set
See Also:
ZipModel.setCompressionMethod(int)

setDirectoryToZip

public void setDirectoryToZip(java.io.File directoryToZip)
Sets the field directoryToZip.

Specified by:
setDirectoryToZip in interface ZipModel
Parameters:
directoryToZip - The directoryToZip to set
See Also:
ZipModel.setDirectoryToZip(java.io.File)

setDirToStart

public void setDirToStart(java.lang.String dirToStart)
Sets the field dirToStart.

Specified by:
setDirToStart in interface ZipModel
Parameters:
dirToStart - The dirToStart to set
See Also:
ZipModel.setDirToStart(java.lang.String)

setFileCounter

public void setFileCounter(int fileCounter)
Sets the field fileCounter.

Specified by:
setFileCounter in interface ZipModel
Parameters:
fileCounter - The fileCounter to set
See Also:
ZipModel.setFileCounter(int)

setFileFilter

public void setFileFilter(java.io.FilenameFilter fileFilter)
Sets the field fileFilter.

Specified by:
setFileFilter in interface ZipModel
Parameters:
fileFilter - The fileFilter to set
See Also:
ZipModel.setFileFilter(java.io.FilenameFilter)

setFileLength

public void setFileLength(long fileLength)
Sets the field fileLength.

Specified by:
setFileLength in interface ZipModel
Parameters:
fileLength - The fileLength to set
See Also:
ZipModel.setFileLength(long)

setZipFile

public void setZipFile(java.io.File zipFile)
Sets the field zipFile.

Specified by:
setZipFile in interface ZipModel
Parameters:
zipFile - The zipFile to set
See Also:
ZipModel.setZipFile(java.io.File)

setZipFileComment

public void setZipFileComment(java.lang.String zipFileComment)
Sets the field zipFileComment.

Specified by:
setZipFileComment in interface ZipModel
Parameters:
zipFileComment - The zipFileComment to set
See Also:
ZipModel.setZipFileComment(java.lang.String)

setZipFileName

public void setZipFileName(java.lang.String zipFileName)
Sets the field zipFileName.

Specified by:
setZipFileName in interface ZipModel
Parameters:
zipFileName - The zipFileName to set
See Also:
ZipModel.setZipFileName(java.lang.String)

setZipFileObj

public void setZipFileObj(java.util.zip.ZipFile zipFileObj)
Sets the field zipFileObj.

Specified by:
setZipFileObj in interface ZipModel
Parameters:
zipFileObj - The zipFileObj to set

setZipLevel

public void setZipLevel(int zipLevel)
Sets the field zipLevel.

Specified by:
setZipLevel in interface ZipModel
Parameters:
zipLevel - The zipLevel to set
See Also:
ZipModel.setZipLevel(int)

zip

public void zip()
Zip.



Copyright © 2010. All Rights Reserved.