Package org.apache.ivy.ant
Class IvyRetrieve
- 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.IvyRetrieve
-
- All Implemented Interfaces:
java.lang.Cloneable
public class IvyRetrieve extends IvyPostResolveTask
This task allow to retrieve dependencies from the cache to a local directory like a lib dir.
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
ivypattern
private org.apache.tools.ant.types.Mapper
mapper
private java.lang.String
overwriteMode
private static java.util.Collection<java.lang.String>
OVERWRITEMODE_VALUES
private java.lang.String
pathId
private java.lang.String
pattern
private java.lang.String
setId
private boolean
symlink
private boolean
symlinkmass
private boolean
sync
-
Fields inherited from class org.apache.ivy.ant.IvyTask
ANT_PROJECT_CONTEXT_KEY
-
-
Constructor Summary
Constructors Constructor Description IvyRetrieve()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
add(org.apache.tools.ant.util.FileNameMapper fileNameMapper)
Add a nested filenamemapper.void
addMapper(org.apache.tools.ant.types.Mapper mapper)
Add a mapper to convert the file names.void
doExecute()
The real logic of task execution after project has been set in the context.protected java.util.Collection<java.lang.String>
getAllowedLogOptions()
java.lang.String
getIvypattern()
java.lang.String
getOverwriteMode()
private java.lang.String
getPath(java.io.File base, java.io.File file)
Returns the path of the file relative to the given base directory.java.lang.String
getPathId()
java.lang.String
getPattern()
java.lang.String
getSetId()
boolean
isSync()
void
setIvypattern(java.lang.String ivypattern)
void
setOverwriteMode(java.lang.String overwriteMode)
void
setPathId(java.lang.String pathId)
void
setPattern(java.lang.String pattern)
void
setSetId(java.lang.String setId)
void
setSymlink(boolean symlink)
Option to create symlinks instead of copying.void
setSymlinkmass(boolean symlinkmass)
Deprecated.Starting 2.5, symlinking in mass isn't supportedvoid
setSync(boolean sync)
-
Methods 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, setupResolve, setUseOrigin
-
Methods 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, toString
-
Methods 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, setTaskType
-
-
-
-
Field Detail
-
OVERWRITEMODE_VALUES
private static final java.util.Collection<java.lang.String> OVERWRITEMODE_VALUES
-
pattern
private java.lang.String pattern
-
ivypattern
private java.lang.String ivypattern
-
sync
private boolean sync
-
symlink
private boolean symlink
-
symlinkmass
private boolean symlinkmass
-
overwriteMode
private java.lang.String overwriteMode
-
pathId
private java.lang.String pathId
-
setId
private java.lang.String setId
-
mapper
private org.apache.tools.ant.types.Mapper mapper
-
-
Method Detail
-
getPattern
public java.lang.String getPattern()
-
setPattern
public void setPattern(java.lang.String pattern)
-
getPathId
public java.lang.String getPathId()
-
setPathId
public void setPathId(java.lang.String pathId)
-
getSetId
public java.lang.String getSetId()
-
setSetId
public void setSetId(java.lang.String setId)
-
doExecute
public void doExecute() throws org.apache.tools.ant.BuildException
Description copied from class:IvyTask
The real logic of task execution after project has been set in the context. MUST be implemented by subclasses
-
getAllowedLogOptions
protected java.util.Collection<java.lang.String> getAllowedLogOptions()
-
getIvypattern
public java.lang.String getIvypattern()
-
setIvypattern
public void setIvypattern(java.lang.String ivypattern)
-
isSync
public boolean isSync()
-
setSync
public void setSync(boolean sync)
-
setSymlink
public void setSymlink(boolean symlink)
Option to create symlinks instead of copying.- Parameters:
symlink
- boolean
-
setSymlinkmass
@Deprecated public void setSymlinkmass(boolean symlinkmass)
Deprecated.Starting 2.5, symlinking in mass isn't supportedOption to create symlinks in one mass action, instead of separately.- Parameters:
symlinkmass
- boolean
-
setOverwriteMode
public void setOverwriteMode(java.lang.String overwriteMode)
-
getOverwriteMode
public java.lang.String getOverwriteMode()
-
addMapper
public void addMapper(org.apache.tools.ant.types.Mapper mapper)
Add a mapper to convert the file names.- Parameters:
mapper
- a Mapper value.
-
add
public void add(org.apache.tools.ant.util.FileNameMapper fileNameMapper)
Add a nested filenamemapper.- Parameters:
fileNameMapper
- the mapper to add.
-
getPath
private java.lang.String getPath(java.io.File base, java.io.File file)
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.
-
-