public final class SubArtifact extends AbstractArtifact
Constructor and Description |
---|
SubArtifact(Artifact mainArtifact,
String classifier,
String extension)
Creates a new sub artifact.
|
SubArtifact(Artifact mainArtifact,
String classifier,
String extension,
File file)
Creates a new sub artifact.
|
SubArtifact(Artifact mainArtifact,
String classifier,
String extension,
Map<String,String> properties)
Creates a new sub artifact.
|
SubArtifact(Artifact mainArtifact,
String classifier,
String extension,
Map<String,String> properties,
File file)
Creates a new sub artifact.
|
Modifier and Type | Method and Description |
---|---|
String |
getArtifactId() |
String |
getBaseVersion() |
String |
getClassifier() |
String |
getExtension() |
File |
getFile() |
String |
getGroupId() |
Map<String,String> |
getProperties() |
String |
getVersion() |
boolean |
isSnapshot() |
Artifact |
setFile(File file) |
Artifact |
setProperties(Map<String,String> properties) |
copyProperties, equals, getProperty, hashCode, setVersion, toString
public SubArtifact(Artifact mainArtifact, String classifier, String extension)
mainArtifact
- The artifact from which to derive the identity, must not be null
.classifier
- The classifier for this artifact, may be null
if none.extension
- The extension for this artifact, may be null
if none.public SubArtifact(Artifact mainArtifact, String classifier, String extension, File file)
mainArtifact
- The artifact from which to derive the identity, must not be null
.classifier
- The classifier for this artifact, may be null
if none.extension
- The extension for this artifact, may be null
if none.file
- The file for this artifact, may be null
if unresolved.public SubArtifact(Artifact mainArtifact, String classifier, String extension, Map<String,String> properties)
mainArtifact
- The artifact from which to derive the identity, must not be null
.classifier
- The classifier for this artifact, may be null
if none.extension
- The extension for this artifact, may be null
if none.properties
- The properties of the artifact, may be null
.public SubArtifact(Artifact mainArtifact, String classifier, String extension, Map<String,String> properties, File file)
mainArtifact
- The artifact from which to derive the identity, must not be null
.classifier
- The classifier for this artifact, may be null
if none.extension
- The extension for this artifact, may be null
if none.properties
- The properties of the artifact, may be null
.file
- The file for this artifact, may be null
if unresolved.public String getGroupId()
public String getArtifactId()
public String getVersion()
public String getBaseVersion()
getBaseVersion
in interface Artifact
getBaseVersion
in class AbstractArtifact
public boolean isSnapshot()
isSnapshot
in interface Artifact
isSnapshot
in class AbstractArtifact
public String getClassifier()
public String getExtension()
public Artifact setFile(File file)
setFile
in interface Artifact
setFile
in class AbstractArtifact
public Map<String,String> getProperties()
public Artifact setProperties(Map<String,String> properties)
setProperties
in interface Artifact
setProperties
in class AbstractArtifact
Copyright © 2010–2021 The Apache Software Foundation. All rights reserved.