@ThreadSafe public class MavenArtifact extends Object implements Serializable
| Constructor and Description |
|---|
MavenArtifact()
Creates an empty MavenArtifact.
|
MavenArtifact(String groupId,
String artifactId,
String version)
Creates a MavenArtifact with the given attributes.
|
MavenArtifact(String groupId,
String artifactId,
String version,
String url)
Creates a MavenArtifact with the given attributes.
|
MavenArtifact(String groupId,
String artifactId,
String version,
String artifactUrl,
String pomUrl)
Creates a MavenArtifact with the given attributes.
|
| Modifier and Type | Method and Description |
|---|---|
static String |
derivePomUrl(String artifactId,
String version,
String artifactUrl)
Tries to determine the URL to the pom.xml.
|
String |
getArtifactId()
Gets the artifactId.
|
String |
getArtifactUrl()
Gets the artifactUrl.
|
String |
getGroupId()
Gets the groupId.
|
String |
getPomUrl()
Get the value of pomUrl.
|
String |
getVersion()
Gets the version.
|
void |
setArtifactId(String artifactId)
Sets the artifactId.
|
void |
setArtifactUrl(String artifactUrl)
Sets the artifactUrl.
|
void |
setGroupId(String groupId)
Sets the groupId.
|
void |
setPomUrl(String pomUrl)
Set the value of pomUrl.
|
void |
setVersion(String version)
Sets the version.
|
String |
toString()
Returns the Artifact coordinates as a String.
|
public MavenArtifact()
public MavenArtifact(String groupId, String artifactId, String version)
groupId - the groupIdartifactId - the artifactIdversion - the versionpublic MavenArtifact(String groupId, String artifactId, String version, String url)
groupId - the groupIdartifactId - the artifactIdversion - the versionurl - the artifactLink URLpublic MavenArtifact(String groupId, String artifactId, String version, String artifactUrl, String pomUrl)
groupId - the groupIdartifactId - the artifactIdversion - the versionartifactUrl - the artifactLink URLpomUrl - the pomUrlpublic static String derivePomUrl(String artifactId, String version, String artifactUrl)
artifactId - the artifact idversion - the versionartifactUrl - the artifact URLpublic String toString()
public String getGroupId()
public void setGroupId(String groupId)
groupId - the groupIdpublic String getArtifactId()
public void setArtifactId(String artifactId)
artifactId - the artifactIdpublic String getVersion()
public void setVersion(String version)
version - the versionpublic String getArtifactUrl()
public void setArtifactUrl(String artifactUrl)
artifactUrl - the artifactUrlpublic String getPomUrl()
public void setPomUrl(String pomUrl)
pomUrl - new value of pomUrlCopyright © 2012–2020 OWASP. All rights reserved.