Package org.apache.ivy.core.retrieve
Class RetrieveEngine
- java.lang.Object
-
- org.apache.ivy.core.retrieve.RetrieveEngine
-
public class RetrieveEngine extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private EventManager
eventManager
private static int
KILO
private RetrieveEngineSettings
settings
-
Constructor Summary
Constructors Constructor Description RetrieveEngine(RetrieveEngineSettings settings, EventManager eventManager)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.util.Map<ArtifactDownloadReport,java.util.Set<java.lang.String>>
determineArtifactsToCopy(ModuleRevisionId mrid, java.lang.String destFilePattern, RetrieveOptions options)
private ResolutionCacheManager
getCache()
private java.util.Comparator<ArtifactDownloadReport>
getConflictResolvingPolicy()
The returned comparator should consider greater the artifact which gains the conflict battle.private java.lang.String[]
getConfs(ModuleRevisionId mrid, RetrieveOptions options)
int
retrieve(ModuleRevisionId mrid, java.lang.String destFilePattern, RetrieveOptions options)
Deprecated.RetrieveReport
retrieve(ModuleRevisionId mrid, RetrieveOptions options)
private void
sync(java.util.Collection<java.io.File> target, java.util.Collection<java.io.File> existing)
private boolean
upToDate(java.io.File source, java.io.File target, RetrieveOptions options)
-
-
-
Field Detail
-
KILO
private static final int KILO
- See Also:
- Constant Field Values
-
settings
private RetrieveEngineSettings settings
-
eventManager
private EventManager eventManager
-
-
Constructor Detail
-
RetrieveEngine
public RetrieveEngine(RetrieveEngineSettings settings, EventManager eventManager)
-
-
Method Detail
-
retrieve
@Deprecated public int retrieve(ModuleRevisionId mrid, java.lang.String destFilePattern, RetrieveOptions options) throws java.io.IOException
Deprecated.example of destFilePattern : - lib/[organisation]/[module]/[artifact]-[revision].[type] - lib/[artifact].[type] : flatten with no revision moduleId is used with confs and localCacheDirectory to determine an ivy report file, used as input for the copy If such a file does not exist for any conf (resolve has not been called before ?) then an IllegalStateException is thrown and nothing is copied.- Parameters:
mrid
- ModuleRevisionIddestFilePattern
- Stringoptions
- RetrieveOptions- Returns:
- int
- Throws:
java.io.IOException
- if something goes wrong
-
retrieve
public RetrieveReport retrieve(ModuleRevisionId mrid, RetrieveOptions options) throws java.io.IOException
- Throws:
java.io.IOException
-
getConfs
private java.lang.String[] getConfs(ModuleRevisionId mrid, RetrieveOptions options) throws java.io.IOException
- Throws:
java.io.IOException
-
getCache
private ResolutionCacheManager getCache()
-
sync
private void sync(java.util.Collection<java.io.File> target, java.util.Collection<java.io.File> existing)
-
determineArtifactsToCopy
public java.util.Map<ArtifactDownloadReport,java.util.Set<java.lang.String>> determineArtifactsToCopy(ModuleRevisionId mrid, java.lang.String destFilePattern, RetrieveOptions options) throws java.text.ParseException, java.io.IOException
- Throws:
java.text.ParseException
java.io.IOException
-
upToDate
private boolean upToDate(java.io.File source, java.io.File target, RetrieveOptions options)
-
getConflictResolvingPolicy
private java.util.Comparator<ArtifactDownloadReport> getConflictResolvingPolicy()
The returned comparator should consider greater the artifact which gains the conflict battle. This is used only during retrieve... prefer resolve conflict manager to resolve conflicts.- Returns:
- Comparator<ArtifactDownloadReport>
-
-