@Service(value="remoteRepositoryContent#default") @Scope(value="prototype") public class RemoteDefaultRepositoryContent extends AbstractDefaultRepositoryContent implements RemoteRepositoryContent
Modifier and Type | Field and Description |
---|---|
private RemoteRepository |
repository |
ARTIFACT_SEPARATOR, artifactMappingProviders, GROUP_SEPARATOR, log, MAVEN_METADATA, PATH_SEPARATOR
Constructor and Description |
---|
RemoteDefaultRepositoryContent() |
Modifier and Type | Method and Description |
---|---|
String |
getId()
Convenience method to get the repository id.
|
RemoteRepository |
getRepository()
Get the repository configuration associated with this
repository content.
|
RepositoryURL |
getURL()
Convenience method to get the repository url.
|
void |
setRepository(RemoteRepository repository)
Set the repository configuration to associate with this
repository content.
|
ArtifactReference |
toArtifactReference(String path)
Convert a path to an artifact reference.
|
RepositoryURL |
toURL(ArtifactReference reference)
Given an ArtifactReference, return the url to the artifact.
|
initialize, toMetadataPath, toMetadataPath, toPath, toPath
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
toPath
private RemoteRepository repository
public RemoteDefaultRepositoryContent()
public String getId()
RemoteRepositoryContent
Convenience method to get the repository id.
Equivalent to calling .getRepository().getId()
getId
in interface RemoteRepositoryContent
public RemoteRepository getRepository()
RemoteRepositoryContent
getRepository
in interface RemoteRepositoryContent
public RepositoryURL getURL()
RemoteRepositoryContent
Convenience method to get the repository url.
Equivalent to calling new RepositoryURL( this.getRepository().getUrl() )
getURL
in interface RemoteRepositoryContent
public void setRepository(RemoteRepository repository)
RemoteRepositoryContent
setRepository
in interface RemoteRepositoryContent
repository
- the repository to associate with this repository content.public ArtifactReference toArtifactReference(String path) throws LayoutException
toArtifactReference
in interface RemoteRepositoryContent
toArtifactReference
in class AbstractDefaultRepositoryContent
path
- the path to convert. (relative or full url path)ArtifactReference
representing the path. (or null if path cannot be converted to
a ArtifactReference
)LayoutException
- if the path cannot be converted to an artifact reference.public RepositoryURL toURL(ArtifactReference reference)
RemoteRepositoryContent
toURL
in interface RemoteRepositoryContent
reference
- the artifact reference to use.Copyright © 2006–2023 The Apache Software Foundation. All rights reserved.