Package org.apache.ivy.ant
Class IvyCacheFileset
java.lang.Object
org.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.ivy.ant.IvyTask
org.apache.ivy.ant.IvyPostResolveTask
org.apache.ivy.ant.IvyCacheTask
org.apache.ivy.ant.IvyCacheFileset
- All Implemented Interfaces:
Cloneable
Creates an ant fileset consisting in all artifacts found during a resolve. Note that this task
is not compatible with the useOrigin mode.
-
Field Summary
FieldsFields inherited from class org.apache.ivy.ant.IvyTask
ANT_PROJECT_CONTEXT_KEYFields inherited from class org.apache.tools.ant.Task
target, taskName, taskType, wrapperFields inherited from class org.apache.tools.ant.ProjectComponent
description, location, project -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidThe real logic of task execution after project has been set in the context.(package private) FilegetBaseDir(File file1, File file2) Returns the common base directory between the passedfile1andfile2.private LinkedList<File>getParents(File file) private StringReturns the path of the file relative to the given base directory.getSetid()(package private) FilerequireCommonBaseDir(List<ArtifactDownloadReport> artifactDownloadReports) Returns a common base directory, determined from thelocal filesof the passedartifactDownloadReports.voidvoidsetUseOrigin(boolean useOrigin) Methods inherited from class org.apache.ivy.ant.IvyCacheTask
getArtifactReportsMethods inherited from class org.apache.ivy.ant.IvyPostResolveTask
createConflict, createDependency, createExclude, ensureResolved, getArtifactFilter, getBranch, getConf, getConfsToResolve, getConfsToResolve, getFile, getLog, getModule, getOrganisation, getResolvedModuleId, getResolvedMrid, getResolvedReport, getResolveId, getResolveMode, getRevision, getType, isChanging, isHaltonfailure, isInline, isKeep, isRefresh, isTransitive, isUseOrigin, prepareAndCheck, setBranch, setCache, setChanging, setConf, setFile, setHaltonfailure, setInline, setKeep, setLog, setModule, setOrganisation, setRefresh, setResolveId, setResolveMode, setRevision, setTransitive, setType, setupResolveMethods inherited from class org.apache.ivy.ant.IvyTask
cacheAttributeNotSupported, doValidate, execute, finalizeTask, getIvyInstance, getProperty, getProperty, getProperty, getProperty, getPubDate, getResolvedConfigurations, getResolvedDescriptor, getResolvedDescriptor, getResolvedDescriptor, getResolvedDescriptor, getResolvedReport, getSettings, getSettingsRef, isValidate, mergeConfs, prepareTask, setResolved, setResolved, setSettingsRef, setValidate, splitConfs, toStringMethods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskTypeMethods inherited from class org.apache.tools.ant.ProjectComponent
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
-
Field Details
-
setid
-
-
Constructor Details
-
IvyCacheFileset
public IvyCacheFileset()
-
-
Method Details
-
getSetid
-
setSetid
-
setUseOrigin
public void setUseOrigin(boolean useOrigin) - Overrides:
setUseOriginin classIvyPostResolveTask
-
doExecute
public void doExecute() throws org.apache.tools.ant.BuildExceptionDescription copied from class:IvyTaskThe real logic of task execution after project has been set in the context. MUST be implemented by subclasses -
requireCommonBaseDir
Returns a common base directory, determined from thelocal filesof the passedartifactDownloadReports. If no common base directory can be determined, this method throws aBuildException- Parameters:
artifactDownloadReports- The artifact download reports for which the common base directory of the artifacts has to be determined- Returns:
- File
-
getPath
Returns the path of the file relative to the given base directory.- Parameters:
base- the parent directory to which the file must be evaluated.file- the file for which the path should be returned- Returns:
- the path of the file relative to the given base directory.
-
getBaseDir
Returns the common base directory between the passedfile1andfile2.The returned base directory will be a parent of both the
file1andfile2or it will benull.- Parameters:
file1- One of the files, for which the common base directory is being sought, may be null.file2- The other file for which the common base directory should be returned, may be null.- Returns:
- the common base directory between a
file1andfile2. Returns null if no common base directory could be determined or if eitherfile1orfile2is null
-
getParents
- Returns:
- a list of files, starting with the root and ending with the file itself
-