Class LegacyLocalRepositoryManager.ArtifactMetadataAdapter
- java.lang.Object
-
- org.apache.maven.artifact.repository.LegacyLocalRepositoryManager.ArtifactMetadataAdapter
-
- All Implemented Interfaces:
ArtifactMetadata
,ArtifactMetadata
- Enclosing class:
- LegacyLocalRepositoryManager
static class LegacyLocalRepositoryManager.ArtifactMetadataAdapter extends java.lang.Object implements ArtifactMetadata
-
-
Field Summary
Fields Modifier and Type Field Description private org.eclipse.aether.metadata.Metadata
metadata
-
Constructor Summary
Constructors Constructor Description ArtifactMetadataAdapter(org.eclipse.aether.metadata.Metadata metadata)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
extendedToString()
java.lang.String
getArtifactId()
java.lang.String
getBaseVersion()
java.lang.String
getGroupId()
java.lang.Object
getKey()
java.lang.String
getLocalFilename(ArtifactRepository repository)
Get the filename of this metadata on the local repository.java.lang.String
getRemoteFilename()
Get the filename of this metadata on the remote repository.private java.lang.String
insertRepositoryKey(java.lang.String filename, java.lang.String repositoryKey)
void
merge(ArtifactMetadata metadata)
void
merge(ArtifactMetadata metadata)
Merge a new metadata set into this piece of metadata.private java.lang.String
nullify(java.lang.String str)
boolean
storedInArtifactVersionDirectory()
Whether this metadata should be stored alongside the artifact.boolean
storedInGroupDirectory()
Whether this metadata should be stored alongside the group.void
storeInLocalRepository(ArtifactRepository localRepository, ArtifactRepository remoteRepository)
Store the metadata in the local repository.
-
-
-
Method Detail
-
storedInArtifactVersionDirectory
public boolean storedInArtifactVersionDirectory()
Description copied from interface:ArtifactMetadata
Whether this metadata should be stored alongside the artifact.- Specified by:
storedInArtifactVersionDirectory
in interfaceArtifactMetadata
-
storedInGroupDirectory
public boolean storedInGroupDirectory()
Description copied from interface:ArtifactMetadata
Whether this metadata should be stored alongside the group.- Specified by:
storedInGroupDirectory
in interfaceArtifactMetadata
-
getGroupId
public java.lang.String getGroupId()
- Specified by:
getGroupId
in interfaceArtifactMetadata
-
getArtifactId
public java.lang.String getArtifactId()
- Specified by:
getArtifactId
in interfaceArtifactMetadata
-
getBaseVersion
public java.lang.String getBaseVersion()
- Specified by:
getBaseVersion
in interfaceArtifactMetadata
-
nullify
private java.lang.String nullify(java.lang.String str)
-
getKey
public java.lang.Object getKey()
- Specified by:
getKey
in interfaceArtifactMetadata
-
getRemoteFilename
public java.lang.String getRemoteFilename()
Description copied from interface:ArtifactMetadata
Get the filename of this metadata on the remote repository.- Specified by:
getRemoteFilename
in interfaceArtifactMetadata
- Returns:
- the filename
-
getLocalFilename
public java.lang.String getLocalFilename(ArtifactRepository repository)
Description copied from interface:ArtifactMetadata
Get the filename of this metadata on the local repository.- Specified by:
getLocalFilename
in interfaceArtifactMetadata
- Parameters:
repository
- the remote repository it came from- Returns:
- the filename
-
insertRepositoryKey
private java.lang.String insertRepositoryKey(java.lang.String filename, java.lang.String repositoryKey)
-
merge
public void merge(ArtifactMetadata metadata)
Description copied from interface:ArtifactMetadata
Merge a new metadata set into this piece of metadata. TODO this should only be needed on the repository metadataArtifactMetadata
- Specified by:
merge
in interfaceArtifactMetadata
- Parameters:
metadata
- the new metadata
-
merge
public void merge(ArtifactMetadata metadata)
- Specified by:
merge
in interfaceArtifactMetadata
-
storeInLocalRepository
public void storeInLocalRepository(ArtifactRepository localRepository, ArtifactRepository remoteRepository) throws RepositoryMetadataStoreException
Description copied from interface:ArtifactMetadata
Store the metadata in the local repository. TODO this should only be needed on the repository metadataArtifactMetadata
- Specified by:
storeInLocalRepository
in interfaceArtifactMetadata
- Parameters:
localRepository
- the local repositoryremoteRepository
- the remote repository it came from- Throws:
RepositoryMetadataStoreException
- in case of issue
-
extendedToString
public java.lang.String extendedToString()
- Specified by:
extendedToString
in interfaceArtifactMetadata
-
-