Interface RepositoryRequest
- All Known Subinterfaces:
MetadataResolutionRequest
- All Known Implementing Classes:
ArtifactResolutionRequest
,DefaultMetadataResolutionRequest
,DefaultRepositoryRequest
public interface RepositoryRequest
Collects basic settings to access the repository system.
- Author:
- Benjamin Bentmann
-
Method Summary
Modifier and TypeMethodDescriptionGets the local repository to use.Gets the remote repositories to use.boolean
Indicates whether remote repositories should be re-checked for updated artifacts/metadata regardless of their configured update policy.boolean
Indicates whether network access to remote repositories has been disabled.setForceUpdate
(boolean forceUpdate) Enables/disabled forced checks for updated artifacts/metadata on remote repositories.setLocalRepository
(ArtifactRepository localRepository) Sets the local repository to use.setOffline
(boolean offline) Enables/disables network access to remote repositories.setRemoteRepositories
(List<ArtifactRepository> remoteRepositories) Sets the remote repositories to use.
-
Method Details
-
isOffline
boolean isOffline()Indicates whether network access to remote repositories has been disabled.- Returns:
true
if remote access has been disabled,false
otherwise.
-
setOffline
Enables/disables network access to remote repositories.- Parameters:
offline
-true
to disable remote access,false
to allow network access.- Returns:
- This request, never
null
.
-
isForceUpdate
boolean isForceUpdate()Indicates whether remote repositories should be re-checked for updated artifacts/metadata regardless of their configured update policy.- Returns:
true
if remote repositories should be re-checked for updated artifacts/metadata,false
otherwise.
-
setForceUpdate
Enables/disabled forced checks for updated artifacts/metadata on remote repositories.- Parameters:
forceUpdate
-true
to forcibly check the remote repositories for updated artifacts/metadata,false
to use the update policy configured on each repository.- Returns:
- This request, never
null
.
-
getLocalRepository
ArtifactRepository getLocalRepository()Gets the local repository to use.- Returns:
- The local repository to use or
null
if not set.
-
setLocalRepository
Sets the local repository to use.- Parameters:
localRepository
- The local repository to use.- Returns:
- This request, never
null
.
-
getRemoteRepositories
List<ArtifactRepository> getRemoteRepositories()Gets the remote repositories to use.- Returns:
- The remote repositories to use, never
null
.
-
setRemoteRepositories
Sets the remote repositories to use.- Parameters:
remoteRepositories
- The remote repositories to use.- Returns:
- This request, never
null
.
-