org.apache.maven.artifact.repository
Interface ArtifactRepository


public interface ArtifactRepository

Abstraction of an artifact repository. Artifact repositories can be remote, local, or even build reactor or IDE workspace.


Method Summary
 Artifact find(Artifact artifact)
           
 List<String> findVersions(Artifact artifact)
          Finds the versions of the specified artifact that are available in this repository.
 Authentication getAuthentication()
           
 String getBasedir()
           
 String getId()
           
 String getKey()
           
 ArtifactRepositoryLayout getLayout()
           
 List<ArtifactRepository> getMirroredRepositories()
           
 String getProtocol()
           
 Proxy getProxy()
           
 ArtifactRepositoryPolicy getReleases()
           
 ArtifactRepositoryPolicy getSnapshots()
           
 String getUrl()
           
 boolean isBlacklisted()
          Deprecated. 
 boolean isProjectAware()
          Indicates whether this repository is backed by actual projects.
 boolean isUniqueVersion()
          Deprecated. 
 String pathOf(Artifact artifact)
           
 String pathOfLocalRepositoryMetadata(ArtifactMetadata metadata, ArtifactRepository repository)
           
 String pathOfRemoteRepositoryMetadata(ArtifactMetadata artifactMetadata)
           
 void setAuthentication(Authentication authentication)
           
 void setBlacklisted(boolean blackListed)
          Deprecated. 
 void setId(String id)
           
 void setLayout(ArtifactRepositoryLayout layout)
           
 void setMirroredRepositories(List<ArtifactRepository> mirroredRepositories)
           
 void setProxy(Proxy proxy)
           
 void setReleaseUpdatePolicy(ArtifactRepositoryPolicy policy)
           
 void setSnapshotUpdatePolicy(ArtifactRepositoryPolicy policy)
           
 void setUrl(String url)
           
 

Method Detail

pathOf

String pathOf(Artifact artifact)

pathOfRemoteRepositoryMetadata

String pathOfRemoteRepositoryMetadata(ArtifactMetadata artifactMetadata)

pathOfLocalRepositoryMetadata

String pathOfLocalRepositoryMetadata(ArtifactMetadata metadata,
                                     ArtifactRepository repository)

getUrl

String getUrl()

setUrl

void setUrl(String url)

getBasedir

String getBasedir()

getProtocol

String getProtocol()

getId

String getId()

setId

void setId(String id)

getSnapshots

ArtifactRepositoryPolicy getSnapshots()

setSnapshotUpdatePolicy

void setSnapshotUpdatePolicy(ArtifactRepositoryPolicy policy)

getReleases

ArtifactRepositoryPolicy getReleases()

setReleaseUpdatePolicy

void setReleaseUpdatePolicy(ArtifactRepositoryPolicy policy)

getLayout

ArtifactRepositoryLayout getLayout()

setLayout

void setLayout(ArtifactRepositoryLayout layout)

getKey

String getKey()

isUniqueVersion

@Deprecated
boolean isUniqueVersion()
Deprecated. 


isBlacklisted

@Deprecated
boolean isBlacklisted()
Deprecated. 


setBlacklisted

@Deprecated
void setBlacklisted(boolean blackListed)
Deprecated. 


find

Artifact find(Artifact artifact)
Parameters:
artifact -
Returns:
Since:
3.0-alpha-3

findVersions

List<String> findVersions(Artifact artifact)
Finds the versions of the specified artifact that are available in this repository.

Parameters:
artifact - The artifact whose available versions should be determined, must not be null.
Returns:
The available versions of the artifact or an empty list if none, never null.
Since:
3.0-alpha-3

isProjectAware

boolean isProjectAware()
Indicates whether this repository is backed by actual projects. For instance, the build reactor or IDE workspace are examples of such repositories.

Returns:
true if the repository is backed by actual projects, false otherwise.
Since:
3.0-beta-1

setAuthentication

void setAuthentication(Authentication authentication)
Since:
3.0-alpha-3

getAuthentication

Authentication getAuthentication()
Since:
3.0-alpha-3

setProxy

void setProxy(Proxy proxy)
Since:
3.0-alpha-3

getProxy

Proxy getProxy()
Since:
3.0-alpha-3

getMirroredRepositories

List<ArtifactRepository> getMirroredRepositories()
Returns:
the repositories mirrored by the actual one
Since:
3.0.3

setMirroredRepositories

void setMirroredRepositories(List<ArtifactRepository> mirroredRepositories)
Parameters:
mirroredRepositories - the repositories that the actual one mirrors
Since:
3.0.3


Copyright © 2001–2013 The Apache Software Foundation. All rights reserved.