org.apache.maven.repository.legacy.metadata
Interface MetadataResolutionRequest

All Superinterfaces:
RepositoryRequest
All Known Implementing Classes:
DefaultMetadataResolutionRequest

public interface MetadataResolutionRequest
extends RepositoryRequest

Forms a request to retrieve artifact metadata.

Author:
Benjamin Bentmann

Method Summary
 Artifact getArtifact()
          Gets the artifact to resolve metadata for.
 ArtifactRepository getLocalRepository()
          Gets the local repository to use for the resolution.
 List<ArtifactRepository> getRemoteRepositories()
          Gets the remote repositories to use for the resolution.
 boolean isOffline()
          Indicates whether network access to remote repositories has been disabled.
 boolean isResolveManagedVersions()
          Determines whether the managed version information should be retrieved.
 MetadataResolutionRequest setArtifact(Artifact artifact)
          Sets the artifact for which to resolve metadata.
 MetadataResolutionRequest setLocalRepository(ArtifactRepository localRepository)
          Sets the local repository to use for the resolution.
 MetadataResolutionRequest setOffline(boolean offline)
          Enables/disables network access to remote repositories.
 MetadataResolutionRequest setRemoteRepositories(List<ArtifactRepository> remoteRepositories)
          Sets the remote repositories to use for the resolution.
 MetadataResolutionRequest setResolveManagedVersions(boolean resolveManagedVersions)
          Enables/disables resolution of the dependency manageemnt information.
 
Methods inherited from interface org.apache.maven.artifact.repository.RepositoryRequest
isForceUpdate, setForceUpdate
 

Method Detail

isOffline

boolean isOffline()
Indicates whether network access to remote repositories has been disabled.

Specified by:
isOffline in interface RepositoryRequest
Returns:
true if remote access has been disabled, false otherwise.

setOffline

MetadataResolutionRequest setOffline(boolean offline)
Enables/disables network access to remote repositories.

Specified by:
setOffline in interface RepositoryRequest
Parameters:
offline - true to disable remote access, false to allow network access.
Returns:
This request, never null.

getArtifact

Artifact getArtifact()
Gets the artifact to resolve metadata for.

Returns:
The artifact to resolve metadata for or null if not set.

setArtifact

MetadataResolutionRequest setArtifact(Artifact artifact)
Sets the artifact for which to resolve metadata.

Parameters:
artifact - The artifact for which to resolve metadata.
Returns:
This request, never null.

getLocalRepository

ArtifactRepository getLocalRepository()
Gets the local repository to use for the resolution.

Specified by:
getLocalRepository in interface RepositoryRequest
Returns:
The local repository to use for the resolution or null if not set.

setLocalRepository

MetadataResolutionRequest setLocalRepository(ArtifactRepository localRepository)
Sets the local repository to use for the resolution.

Specified by:
setLocalRepository in interface RepositoryRequest
Parameters:
localRepository - The local repository to use for the resolution.
Returns:
This request, never null.

getRemoteRepositories

List<ArtifactRepository> getRemoteRepositories()
Gets the remote repositories to use for the resolution.

Specified by:
getRemoteRepositories in interface RepositoryRequest
Returns:
The remote repositories to use for the resolution, never null.

setRemoteRepositories

MetadataResolutionRequest setRemoteRepositories(List<ArtifactRepository> remoteRepositories)
Sets the remote repositories to use for the resolution.

Specified by:
setRemoteRepositories in interface RepositoryRequest
Parameters:
remoteRepositories - The remote repositories to use for the resolution.
Returns:
This request, never null.

isResolveManagedVersions

boolean isResolveManagedVersions()
Determines whether the managed version information should be retrieved.

Returns:
true if the dependency management information should be retrieved, false otherwise.

setResolveManagedVersions

MetadataResolutionRequest setResolveManagedVersions(boolean resolveManagedVersions)
Enables/disables resolution of the dependency manageemnt information.

Parameters:
resolveManagedVersions - true if the dependency management information should be retrieved, false otherwise.
Returns:
This request, never null.


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