public class ArchiveFileExportOperation
extends java.lang.Object
Constructor and Description |
---|
ArchiveFileExportOperation(IResource res,
java.util.List<IResource> resources,
java.lang.String filename)
Create an instance of this class.
|
ArchiveFileExportOperation(IResource res,
java.lang.String filename)
Create an instance of this class.
|
ArchiveFileExportOperation(java.util.List<IResource> resources,
java.lang.String filename)
Create an instance of this class.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addError(java.lang.String message,
java.lang.Throwable e)
Add a new entry to the error table with the passed information
|
protected int |
countChildrenOf(IResource checkResource)
Answer the total number of file resources that exist at or below self
in the resources hierarchy.
|
protected int |
countSelectedResources()
Answer a boolean indicating the number of file resources that were
specified for export
|
protected void |
exportResource(IResource exportResource)
Export the passed resource to the destination .zip.
|
protected void |
exportResource(IResource exportResource,
int leadupDepth)
Export the passed resource to the destination .zip
|
protected void |
exportSpecifiedResources()
Export the resources contained in the previously-defined
resourcesToExport collection
|
java.util.List<IStatus> |
getResult()
Answer the error table
|
IStatus |
getStatus()
Returns the status of the operation.
|
protected void |
initialize()
Initialize this operation
|
protected boolean |
isDescendent(java.util.List<IResource> resources,
IResource child)
Answer a boolean indicating whether the passed child is a descendent
of one or more members of the passed resources collection
|
void |
run(IProgressMonitor progressMonitor)
Export the resources that were previously specified for export
(or if a single resource was specified then export it recursively)
|
void |
setCreateLeadupStructure(boolean value)
Set this boolean indicating whether each exported resource's path should
include containment hierarchies as dictated by its parents
|
void |
setUseCompression(boolean value)
Set this boolean indicating whether exported resources should
be compressed (as opposed to simply being stored)
|
public ArchiveFileExportOperation(java.util.List<IResource> resources, java.lang.String filename)
resources
- java.util.Vectorfilename
- java.lang.Stringpublic ArchiveFileExportOperation(IResource res, java.lang.String filename)
res
- org.eclipse.core.resources.IResource;filename
- java.lang.Stringpublic ArchiveFileExportOperation(IResource res, java.util.List<IResource> resources, java.lang.String filename)
res
- org.eclipse.core.resources.IResourceresources
- java.util.Vectorfilename
- java.lang.Stringprotected void addError(java.lang.String message, java.lang.Throwable e)
protected int countChildrenOf(IResource checkResource) throws CoreException
checkResource
- org.eclipse.core.resources.IResourceCoreException
protected int countSelectedResources() throws CoreException
CoreException
protected void exportResource(IResource exportResource) throws java.lang.InterruptedException
exportResource
- org.eclipse.core.resources.IResourcejava.lang.InterruptedException
protected void exportResource(IResource exportResource, int leadupDepth) throws java.lang.InterruptedException
exportResource
- org.eclipse.core.resources.IResourceleadupDepth
- the number of resource levels to be included in
the path including the resourse itself.java.lang.InterruptedException
protected void exportSpecifiedResources() throws java.lang.InterruptedException
java.lang.InterruptedException
public java.util.List<IStatus> getResult()
public IStatus getStatus()
OK
.protected void initialize() throws java.io.IOException
java.io.IOException
protected boolean isDescendent(java.util.List<IResource> resources, IResource child)
resources
- java.util.Vectorchild
- org.eclipse.core.resources.IResourcepublic void run(IProgressMonitor progressMonitor) throws java.lang.reflect.InvocationTargetException, java.lang.InterruptedException
java.lang.reflect.InvocationTargetException
java.lang.InterruptedException
public void setCreateLeadupStructure(boolean value)
value
- booleanpublic void setUseCompression(boolean value)
value
- boolean