|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.continuum.purge.repository.content.ManagedLegacyRepositoryContent
public class ManagedLegacyRepositoryContent
Taken from Archiva's ManagedLegacyRepositoryContent and made some few changes
Constructor Summary | |
---|---|
ManagedLegacyRepositoryContent()
|
Method Summary | |
---|---|
void |
deleteVersion(org.apache.maven.archiva.model.VersionedReference reference)
Delete from the local repository all files / directories associated with the provided version reference. |
int |
getId()
Convenience method to get the repository id. |
Set<org.apache.maven.archiva.model.ArtifactReference> |
getRelatedArtifacts(org.apache.maven.archiva.model.ArtifactReference reference)
Gather up the list of related artifacts to the ArtifactReference provided. |
String |
getRepoRoot()
Convenience method to get the repository (on disk) root directory. |
LocalRepository |
getRepository()
Get the local repository associated with this repository content. |
Set<String> |
getVersions(org.apache.maven.archiva.model.ProjectReference reference)
Given a specific ProjectReference , return the list of available versions for
that project reference. |
Set<String> |
getVersions(org.apache.maven.archiva.model.VersionedReference reference)
Given a specific VersionedReference , return the list of available versions for that
versioned reference. |
void |
setRepository(LocalRepository repo)
Set the local repository to associate with this repository content. |
org.apache.maven.archiva.model.ArtifactReference |
toArtifactReference(String path)
Convert a path to an artifact reference. |
File |
toFile(org.apache.maven.archiva.model.ArtifactReference reference)
Given an ArtifactReference , return the file reference to the artifact. |
String |
toMetadataPath(org.apache.maven.archiva.model.ProjectReference reference)
Given a ProjectReference , return the path to the metadata for
the project. |
String |
toMetadataPath(org.apache.maven.archiva.model.VersionedReference reference)
Given a VersionedReference , return the path to the metadata for
the specific version of the project. |
String |
toPath(org.apache.maven.archiva.model.ArtifactReference reference)
Given an ArtifactReference , return the relative path to the artifact. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ManagedLegacyRepositoryContent()
Method Detail |
---|
public void deleteVersion(org.apache.maven.archiva.model.VersionedReference reference) throws org.apache.maven.archiva.repository.ContentNotFoundException
RepositoryManagedContent
deleteVersion
in interface RepositoryManagedContent
reference
- the version reference to delete.
org.apache.maven.archiva.repository.ContentNotFoundException
public int getId()
RepositoryManagedContent
Convenience method to get the repository id.
Equivalent to calling .getRepository().getId()
getId
in interface RepositoryManagedContent
public Set<org.apache.maven.archiva.model.ArtifactReference> getRelatedArtifacts(org.apache.maven.archiva.model.ArtifactReference reference) throws org.apache.maven.archiva.repository.ContentNotFoundException, org.apache.maven.archiva.repository.layout.LayoutException
RepositoryManagedContent
Gather up the list of related artifacts to the ArtifactReference provided. This typically inclues the pom files, and those things with classifiers (such as doc, source code, test libs, etc...)
NOTE: Some layouts (such as maven 1 "legacy") are not compatible with this query.
getRelatedArtifacts
in interface RepositoryManagedContent
reference
- the reference to work off of.
org.apache.maven.archiva.repository.ContentNotFoundException
- if the initial artifact reference does not exist within the repository.
org.apache.maven.archiva.repository.layout.LayoutException
public String getRepoRoot()
RepositoryManagedContent
Convenience method to get the repository (on disk) root directory.
Equivalent to calling .getLocalRepository().getDirectory()
getRepoRoot
in interface RepositoryManagedContent
public LocalRepository getRepository()
RepositoryManagedContent
getRepository
in interface RepositoryManagedContent
public Set<String> getVersions(org.apache.maven.archiva.model.ProjectReference reference) throws org.apache.maven.archiva.repository.ContentNotFoundException
RepositoryManagedContent
ProjectReference
, return the list of available versions for
that project reference.
getVersions
in interface RepositoryManagedContent
reference
- the project reference to work off of.
org.apache.maven.archiva.repository.ContentNotFoundException
- if the project reference does not exist within the repository.public Set<String> getVersions(org.apache.maven.archiva.model.VersionedReference reference) throws org.apache.maven.archiva.repository.ContentNotFoundException
RepositoryManagedContent
Given a specific VersionedReference
, return the list of available versions for that
versioned reference.
NOTE: This is really only useful when working with SNAPSHOTs.
getVersions
in interface RepositoryManagedContent
reference
- the versioned reference to work off of.
org.apache.maven.archiva.repository.ContentNotFoundException
- if the versioned reference does not exist within the repository.public org.apache.maven.archiva.model.ArtifactReference toArtifactReference(String path) throws org.apache.maven.archiva.repository.layout.LayoutException
toArtifactReference
in interface RepositoryManagedContent
path
- the path to convert. (relative or full location path)
ArtifactReference
representing the path. (or null if path cannot be converted to
a ArtifactReference
)
org.apache.maven.archiva.repository.layout.LayoutException
- if the path cannot be converted to an artifact reference.public File toFile(org.apache.maven.archiva.model.ArtifactReference reference)
RepositoryManagedContent
ArtifactReference
, return the file reference to the artifact.
toFile
in interface RepositoryManagedContent
reference
- the artifact reference to use.
public String toMetadataPath(org.apache.maven.archiva.model.ProjectReference reference)
RepositoryManagedContent
ProjectReference
, return the path to the metadata for
the project.
toMetadataPath
in interface RepositoryManagedContent
reference
- the reference to use.
public String toMetadataPath(org.apache.maven.archiva.model.VersionedReference reference)
RepositoryManagedContent
VersionedReference
, return the path to the metadata for
the specific version of the project.
toMetadataPath
in interface RepositoryManagedContent
reference
- the reference to use.
public String toPath(org.apache.maven.archiva.model.ArtifactReference reference)
RepositoryManagedContent
ArtifactReference
, return the relative path to the artifact.
toPath
in interface RepositoryManagedContent
reference
- the artifact reference to use.
public void setRepository(LocalRepository repo)
RepositoryManagedContent
setRepository
in interface RepositoryManagedContent
repo
- the repository to associate with this repository content.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |