public class CacheResolver extends FileSystemResolver
DATE_FORMAT, DESCRIPTOR_OPTIONAL, DESCRIPTOR_REQUIRED
Constructor and Description |
---|
CacheResolver() |
CacheResolver(ResolverSettings settings) |
Modifier and Type | Method and Description |
---|---|
DownloadReport |
download(Artifact[] artifacts,
DownloadOptions options)
Download artifacts with specified DownloadOptions.
|
void |
dumpSettings() |
boolean |
exists(Artifact artifact)
Returns
true if the given artifact can be located by this resolver and actually
exist. |
ResolvedModuleRevision |
getDependency(DependencyDescriptor dd,
ResolveData data)
Resolve a module by id, getting its module descriptor and resolving the revision if it's a
latest one (i.e.
|
java.lang.String |
getTypeName() |
ModuleEntry[] |
listModules(OrganisationEntry org) |
OrganisationEntry[] |
listOrganisations() |
RevisionEntry[] |
listRevisions(ModuleEntry module) |
ArtifactOrigin |
locate(Artifact artifact)
Default implementation actually download the artifact Subclasses should overwrite this to
avoid the download
|
void |
publish(Artifact artifact,
java.io.File src,
boolean overwrite) |
abortPublishTransaction, addArtifactPattern, addConfiguredArtifact, addConfiguredIvy, addIvyPattern, beginPublishTransaction, commitPublishTransaction, filterNames, getDestination, getTransactional, isLocal, setLocal, setTransactional, supportTransaction
exist, findResourceUsingPattern, findTokenValues, get, getRepository, getResource, isAlwaysCheckExactRevision, listResources, listTokenValues, put, putChecksum, putSignature, setAlwaysCheckExactRevision, setName, setRepository, setSettings, setSigner
convertM2IdForResourceSearch, convertM2OrganizationForResourceSearch, convertM2ResourceSearchIdToNormal, convertM2TokenValuesForResourceSearch, findArtifactNames, findArtifactRef, findIvyFileRef, findIvyNames, findNames, findResource, findResourceUsingPatterns, getArtifactPatterns, getIvyPatterns, getModuleDescriptorExtension, isM2compatible, listTokenValues, setArtifactPatterns, setIvyPatterns, setM2compatible
acceptLatest, checkModuleDescriptorRevision, clearArtifactAttempts, clearIvyAttempts, doFindArtifactRef, download, findFirstArtifactRef, getAndCheck, getArtifactRef, getChecksumAlgorithms, getDefaultRMDParser, getPublicationDate, getRMDParser, getWorkspaceName, isAllownomd, isCheckconsistency, isEnvDependent, isForce, listTokenValues, logArtifactAttempt, logAttempt, logIvyAttempt, parse, reportFailure, reportFailure, setAllownomd, setCheckconsistency, setChecksums, setDescriptor, setEnvDependent, setForce, setWorkspaceName, shouldReturnResolvedModule, toString
checkInterrupted, checkLatest, doValidate, findModuleInCache, findModuleInCache, fromSystem, fromSystem, getCacheDownloadOptions, getCacheOptions, getChangingMatcherName, getChangingPattern, getDownloadOptions, getEventManager, getLatest, getLatestStrategy, getName, getNamespace, getParserSettings, getRepositoryCacheManager, getSettings, getSystemNode, hidePassword, isAfter, isValidate, saveModuleRevisionIfNeeded, setCache, setChangingMatcher, setChangingPattern, setCheckmodified, setEventManager, setLatest, setLatestStrategy, setNamespace, setRepositoryCacheManager, setValidate, toSystem, toSystem, toSystem, toSystem, toSystem, toSystem, validate
public CacheResolver()
public CacheResolver(ResolverSettings settings)
public ResolvedModuleRevision getDependency(DependencyDescriptor dd, ResolveData data) throws java.text.ParseException
DependencyResolver
getDependency
in interface DependencyResolver
getDependency
in class BasicResolver
java.text.ParseException
public DownloadReport download(Artifact[] artifacts, DownloadOptions options)
DependencyResolver
The resolver will always make a best effort, and do not stop when an artifact is not available. It rather continue to attempt to download other requested artifacts, and report what has been done in the returned DownloadReport.
The returned DownloadReport is never null
, and always contain an
ArtifactDownloadReport
for each requested Artifact.
download
in interface DependencyResolver
download
in class RepositoryResolver
artifacts
- an array of artifacts to download. Must not be null
.options
- options to apply for this download. Must not be null
.public boolean exists(Artifact artifact)
DependencyResolver
true
if the given artifact can be located by this resolver and actually
exist.exists
in interface DependencyResolver
exists
in class BasicResolver
artifact
- the artifact which should be tested.true
if the given artifact can be located by this resolver and actually
exist.public ArtifactOrigin locate(Artifact artifact)
AbstractResolver
locate
in interface DependencyResolver
locate
in class BasicResolver
artifact
- the artifact which should be locatednull
if it can't be located by this resolver
or doesn't exist.public void publish(Artifact artifact, java.io.File src, boolean overwrite) throws java.io.IOException
publish
in interface DependencyResolver
publish
in class RepositoryResolver
java.io.IOException
public OrganisationEntry[] listOrganisations()
listOrganisations
in interface DependencyResolver
listOrganisations
in class BasicResolver
public ModuleEntry[] listModules(OrganisationEntry org)
listModules
in interface DependencyResolver
listModules
in class BasicResolver
public RevisionEntry[] listRevisions(ModuleEntry module)
listRevisions
in interface DependencyResolver
listRevisions
in class BasicResolver
public void dumpSettings()
dumpSettings
in interface DependencyResolver
dumpSettings
in class RepositoryResolver
public java.lang.String getTypeName()
getTypeName
in class FileSystemResolver