Class MavenArtifactRepository
java.lang.Object
org.apache.maven.artifact.repository.MavenArtifactRepository
- All Implemented Interfaces:
 ArtifactRepository
- Direct Known Subclasses:
 DelegatingLocalArtifactRepository,LocalArtifactRepository
Abstraction of an artifact repository. Artifact repositories can be remote, local, or even build reactor or
 IDE workspace.
- 
Constructor Summary
ConstructorsConstructorDescriptionMavenArtifactRepository(String id, String url, ArtifactRepositoryLayout layout, ArtifactRepositoryPolicy snapshots, ArtifactRepositoryPolicy releases) Create a remote download repository. - 
Method Summary
Modifier and TypeMethodDescriptionprotected static <T> booleaneq(T s1, T s2) booleanfindVersions(Artifact artifact) Finds the versions of the specified artifact that are available in this repository.getId()getKey()getProxy()getUrl()inthashCode()booleanbooleanbooleanIndicates whether this repository is backed by actual projects.booleanpathOfLocalRepositoryMetadata(ArtifactMetadata metadata, ArtifactRepository repository) pathOfRemoteRepositoryMetadata(ArtifactMetadata artifactMetadata) voidsetAuthentication(Authentication authentication) voidsetBlacklisted(boolean blackListed) voidsetBlocked(boolean blocked) voidvoidsetLayout(ArtifactRepositoryLayout layout) voidsetMirroredRepositories(List<ArtifactRepository> mirroredRepositories) voidvoidvoidsetSnapshotUpdatePolicy(ArtifactRepositoryPolicy snapshots) voidtoString() 
- 
Constructor Details
- 
MavenArtifactRepository
public MavenArtifactRepository() - 
MavenArtifactRepository
public MavenArtifactRepository(String id, String url, ArtifactRepositoryLayout layout, ArtifactRepositoryPolicy snapshots, ArtifactRepositoryPolicy releases) Create a remote download repository.- Parameters:
 id- the unique identifier of the repositoryurl- the URL of the repositorylayout- the layout of the repositorysnapshots- the policies to use for snapshotsreleases- the policies to use for releases
 
 - 
 - 
Method Details
- 
pathOf
- Specified by:
 pathOfin interfaceArtifactRepository
 - 
pathOfRemoteRepositoryMetadata
- Specified by:
 pathOfRemoteRepositoryMetadatain interfaceArtifactRepository
 - 
pathOfLocalRepositoryMetadata
public String pathOfLocalRepositoryMetadata(ArtifactMetadata metadata, ArtifactRepository repository) - Specified by:
 pathOfLocalRepositoryMetadatain interfaceArtifactRepository
 - 
setLayout
- Specified by:
 setLayoutin interfaceArtifactRepository
 - 
getLayout
- Specified by:
 getLayoutin interfaceArtifactRepository
 - 
setSnapshotUpdatePolicy
- Specified by:
 setSnapshotUpdatePolicyin interfaceArtifactRepository
 - 
getSnapshots
- Specified by:
 getSnapshotsin interfaceArtifactRepository
 - 
setReleaseUpdatePolicy
- Specified by:
 setReleaseUpdatePolicyin interfaceArtifactRepository
 - 
getReleases
- Specified by:
 getReleasesin interfaceArtifactRepository
 - 
getKey
- Specified by:
 getKeyin interfaceArtifactRepository
 - 
toString
 - 
find
- Specified by:
 findin interfaceArtifactRepository- Parameters:
 artifact- an artifact- Returns:
 - found artifact
 
 - 
findVersions
Description copied from interface:ArtifactRepositoryFinds the versions of the specified artifact that are available in this repository.- Specified by:
 findVersionsin interfaceArtifactRepository- Parameters:
 artifact- The artifact whose available versions should be determined, must not benull.- Returns:
 - The available versions of the artifact or an empty list if none, never 
null. 
 - 
getId
- Specified by:
 getIdin interfaceArtifactRepository
 - 
getUrl
- Specified by:
 getUrlin interfaceArtifactRepository
 - 
getBasedir
- Specified by:
 getBasedirin interfaceArtifactRepository
 - 
getProtocol
- Specified by:
 getProtocolin interfaceArtifactRepository
 - 
setId
- Specified by:
 setIdin interfaceArtifactRepository
 - 
setUrl
- Specified by:
 setUrlin interfaceArtifactRepository
 - 
hashCode
public int hashCode() - 
equals
 - 
eq
protected static <T> boolean eq(T s1, T s2)  - 
getAuthentication
- Specified by:
 getAuthenticationin interfaceArtifactRepository- Returns:
 - repository authentication
 
 - 
setAuthentication
- Specified by:
 setAuthenticationin interfaceArtifactRepository- Parameters:
 authentication- authentication
 - 
getProxy
- Specified by:
 getProxyin interfaceArtifactRepository- Returns:
 - repository proxy
 
 - 
setProxy
- Specified by:
 setProxyin interfaceArtifactRepository- Parameters:
 proxy- proxy
 - 
isBlacklisted
public boolean isBlacklisted()- Specified by:
 isBlacklistedin interfaceArtifactRepository
 - 
setBlacklisted
public void setBlacklisted(boolean blackListed) - Specified by:
 setBlacklistedin interfaceArtifactRepository
 - 
isUniqueVersion
public boolean isUniqueVersion()- Specified by:
 isUniqueVersionin interfaceArtifactRepository
 - 
isProjectAware
public boolean isProjectAware()Description copied from interface:ArtifactRepositoryIndicates whether this repository is backed by actual projects. For instance, the build reactor or IDE workspace are examples of such repositories.- Specified by:
 isProjectAwarein interfaceArtifactRepository- Returns:
 trueif the repository is backed by actual projects,falseotherwise.
 - 
getMirroredRepositories
- Specified by:
 getMirroredRepositoriesin interfaceArtifactRepository- Returns:
 - the repositories mirrored by the actual one
 
 - 
setMirroredRepositories
- Specified by:
 setMirroredRepositoriesin interfaceArtifactRepository- Parameters:
 mirroredRepositories- the repositories that the actual one mirrors
 - 
isBlocked
public boolean isBlocked()- Specified by:
 isBlockedin interfaceArtifactRepository- Returns:
 - whether the repository is blocked
 
 - 
setBlocked
public void setBlocked(boolean blocked) - Specified by:
 setBlockedin interfaceArtifactRepository- Parameters:
 blocked- block the repository?
 
 -