org.apache.tools.ant.taskdefs
public abstract class Pack extends Task
Since: Ant 1.5
| Field Summary | |
|---|---|
| protected File | source |
| protected File | zipFile |
| Method Summary | |
|---|---|
| void | addConfigured(ResourceCollection a)
Set the source resource. |
| void | execute()
validate, then hand off to the subclass |
| Resource | getSrcResource()
The source resource. |
| protected abstract void | pack()
subclasses must implement this method to do their compression |
| void | setDestfile(File zipFile)
the required destination file. |
| void | setSrc(File src)
the file to compress; required. |
| void | setSrcResource(Resource src)
The resource to pack; required. |
| void | setZipfile(File zipFile)
the required destination file. |
| protected boolean | supportsNonFileResources()
Whether this task can deal with non-file resources.
|
| protected void | zipFile(File file, OutputStream zOut)
zip a file to an output stream |
| protected void | zipResource(Resource resource, OutputStream zOut)
zip a resource to an output stream |
Parameters: a the resource to pack as a single element Resource collection.
Throws: BuildException on error
Returns: the source.
Since: Ant 1.7
Parameters: zipFile the destination file
Parameters: src the source file
Parameters: src resource to expand
Parameters: zipFile the destination file
This implementation returns false.
Returns: false.
Since: Ant 1.7
Parameters: file the file to zip zOut the output stream
Throws: IOException on error
Parameters: resource the resource to zip zOut the output stream
Throws: IOException on error