Class Metadata
- java.lang.Object
-
- org.apache.maven.artifact.repository.metadata.Metadata
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
public class Metadata extends java.lang.Object implements java.io.Serializable, java.lang.Cloneable
Class Metadata.- Version:
- $Revision$ $Date$
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
artifactId
The artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".private java.lang.String
groupId
The groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".private java.lang.String
modelEncoding
Field modelEncoding.private java.lang.String
modelVersion
The version of the underlying metadata model.private java.util.List<Plugin>
plugins
Deprecated.private java.lang.String
version
The base version (ie.private Versioning
versioning
Versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".
-
Constructor Summary
Constructors Constructor Description Metadata()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addPlugin(Plugin plugin)
Method addPlugin.Metadata
clone()
Method clone.java.lang.String
getArtifactId()
Get the artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".java.lang.String
getGroupId()
Get the groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".java.lang.String
getModelEncoding()
Get the modelEncoding field.java.lang.String
getModelVersion()
Get the version of the underlying metadata model.java.util.List<Plugin>
getPlugins()
Method getPlugins.private java.lang.String
getSnapshotVersionKey(SnapshotVersion sv)
java.lang.String
getVersion()
Get the base version (ie.Versioning
getVersioning()
Get versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".boolean
merge(Metadata sourceMetadata)
void
removePlugin(Plugin plugin)
Method removePlugin.void
setArtifactId(java.lang.String artifactId)
Set the artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".void
setGroupId(java.lang.String groupId)
Set the groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".void
setModelEncoding(java.lang.String modelEncoding)
Set the modelEncoding field.void
setModelVersion(java.lang.String modelVersion)
Set the version of the underlying metadata model.void
setPlugins(java.util.List<Plugin> plugins)
Set the set of plugins when this directory represents a "groupId" (deprecated).void
setVersion(java.lang.String version)
Set the base version (ie.void
setVersioning(Versioning versioning)
Set versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".
-
-
-
Field Detail
-
modelVersion
private java.lang.String modelVersion
The version of the underlying metadata model.
-
groupId
private java.lang.String groupId
The groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".
-
artifactId
private java.lang.String artifactId
The artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".
-
versioning
private Versioning versioning
Versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".
-
version
private java.lang.String version
The base version (ie. ending in-SNAPSHOT
) when this directory represents a "groupId/artifactId/version" for a SNAPSHOT.
-
plugins
@Deprecated private java.util.List<Plugin> plugins
Deprecated.Field plugins.
-
modelEncoding
private java.lang.String modelEncoding
Field modelEncoding.
-
-
Method Detail
-
addPlugin
public void addPlugin(Plugin plugin)
Method addPlugin.- Parameters:
plugin
- a plugin object.
-
clone
public Metadata clone()
Method clone.- Overrides:
clone
in classjava.lang.Object
- Returns:
- Metadata
-
getArtifactId
public java.lang.String getArtifactId()
Get the artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Returns:
- String
-
getGroupId
public java.lang.String getGroupId()
Get the groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Returns:
- String
-
getModelEncoding
public java.lang.String getModelEncoding()
Get the modelEncoding field.- Returns:
- String
-
getModelVersion
public java.lang.String getModelVersion()
Get the version of the underlying metadata model.- Returns:
- String
-
getPlugins
public java.util.List<Plugin> getPlugins()
Method getPlugins.- Returns:
- List
-
getVersion
public java.lang.String getVersion()
Get the base version (ie. ending in-SNAPSHOT
) when this directory represents a "groupId/artifactId/version" for a SNAPSHOT.- Returns:
- String
-
getVersioning
public Versioning getVersioning()
Get versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Returns:
- Versioning
-
removePlugin
public void removePlugin(Plugin plugin)
Method removePlugin.- Parameters:
plugin
- a plugin object.
-
setArtifactId
public void setArtifactId(java.lang.String artifactId)
Set the artifactId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Parameters:
artifactId
- a artifactId object.
-
setGroupId
public void setGroupId(java.lang.String groupId)
Set the groupId when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Parameters:
groupId
- a groupId object.
-
setModelEncoding
public void setModelEncoding(java.lang.String modelEncoding)
Set the modelEncoding field.- Parameters:
modelEncoding
- a modelEncoding object.
-
setModelVersion
public void setModelVersion(java.lang.String modelVersion)
Set the version of the underlying metadata model.- Parameters:
modelVersion
- a modelVersion object.
-
setPlugins
public void setPlugins(java.util.List<Plugin> plugins)
Set the set of plugins when this directory represents a "groupId" (deprecated).- Parameters:
plugins
- a plugins object.
-
setVersion
public void setVersion(java.lang.String version)
Set the base version (ie. ending in-SNAPSHOT
) when this directory represents a "groupId/artifactId/version" for a SNAPSHOT.- Parameters:
version
- a version object.
-
setVersioning
public void setVersioning(Versioning versioning)
Set versioning information when this directory represents "groupId/artifactId" or "groupId/artifactId/version".- Parameters:
versioning
- a versioning object.
-
getSnapshotVersionKey
private java.lang.String getSnapshotVersionKey(SnapshotVersion sv)
-
merge
public boolean merge(Metadata sourceMetadata)
-
-