public final class ZipResource extends CommonsCompressArchiveResource
| Constructor and Description |
|---|
ZipResource()
Default constructor.
|
ZipResource(java.io.File z,
java.lang.String enc,
org.apache.commons.compress.archivers.zip.ZipArchiveEntry e)
Construct a ZipResource representing the specified
entry in the specified zipfile.
|
ZipResource(org.apache.tools.ant.types.Resource z,
java.lang.String enc,
org.apache.commons.compress.archivers.zip.ZipArchiveEntry e)
Construct a ZipResource representing the specified
entry in the specified zip archive.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
fetchEntry()
fetches information from the named entry inside the archive.
|
org.apache.commons.compress.archivers.zip.ZipExtraField[] |
getExtraFields()
Retrieves extra fields.
|
java.io.InputStream |
getInputStream()
Return an InputStream for reading the contents of this Resource.
|
int |
getMethod()
The compression method that has been used.
|
java.io.File |
getZipfile()
Get the zipfile that holds this ZipResource.
|
protected void |
setEntry(org.apache.commons.compress.archivers.ArchiveEntry e) |
void |
setZipfile(java.io.File z)
Set the zipfile that holds this ZipResource.
|
void |
setZipResource(org.apache.tools.ant.types.Resource z)
Set the zipfile that holds this ZipResource.
|
getEncoding, getGid, getOutputStream, getUid, setEncoding, setRefidaddConfigured, checkEntry, compareTo, dieOnCircularReference, equals, getArchive, getLastModified, getMode, getSize, hashCode, isDirectory, isExists, setArchive, setMode, toStringas, clone, getMagicNumber, getName, isFilesystemOnly, iterator, setDirectory, setExists, setLastModified, setName, setSize, size, toLongStringcheckAttributesAllowed, checkChildrenAllowed, circularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, tooManyAttributesgetDescription, getLocation, getProject, log, log, setDescription, setLocation, setProjectpublic ZipResource()
public ZipResource(java.io.File z,
java.lang.String enc,
org.apache.commons.compress.archivers.zip.ZipArchiveEntry e)
z - the zipfile as File.enc - the encoding used for filenames.e - the ZipEntry.public ZipResource(org.apache.tools.ant.types.Resource z,
java.lang.String enc,
org.apache.commons.compress.archivers.zip.ZipArchiveEntry e)
z - the zipfile as File.enc - the encoding used for filenames.e - the ZipEntry.public void setZipfile(java.io.File z)
z - the zipfile as a File.public void setZipResource(org.apache.tools.ant.types.Resource z)
z - the zipfile as a Resource.public java.io.File getZipfile()
public java.io.InputStream getInputStream()
throws java.io.IOException
getInputStream in class CommonsCompressArchiveResourcejava.io.IOException - if the zip file cannot be opened,
or the entry cannot be read.public org.apache.commons.compress.archivers.zip.ZipExtraField[] getExtraFields()
public int getMethod()
protected void fetchEntry()
fetchEntry in class CommonsCompressArchiveResourceprotected void setEntry(org.apache.commons.compress.archivers.ArchiveEntry e)
setEntry in class CommonsCompressArchiveResource