Package fr.brouillard.oss.jgitver
Class GAV
- java.lang.Object
-
- fr.brouillard.oss.jgitver.GAV
-
public class GAV extends Object
Wrapper for a maven project/dependency identified by a groupId/artifactId/version.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)static GAVfrom(org.apache.maven.model.Model model)Builds a GAV object from the given Model object.static GAVfrom(org.apache.maven.model.Parent parent)Builds a GAV object from the given Parent object.static GAVfrom(org.apache.maven.project.MavenProject project)Builds a GAV object from the given MavenProject object.StringgetArtifactId()Retrieves the artifactId.StringgetGroupId()Retrieves the groupId.StringgetVersion()Retrieves the version.inthashCode()voidsetArtifactId(String artifactId)voidsetGroupId(String groupId)voidsetVersion(String version)StringtoString()
-
-
-
Method Detail
-
getGroupId
public String getGroupId()
Retrieves the groupId.- Returns:
- the groupId
-
getArtifactId
public String getArtifactId()
Retrieves the artifactId.- Returns:
- the artifactId
-
getVersion
public String getVersion()
Retrieves the version.- Returns:
- the version
-
setGroupId
public void setGroupId(String groupId)
-
setArtifactId
public void setArtifactId(String artifactId)
-
setVersion
public void setVersion(String version)
-
from
public static GAV from(org.apache.maven.project.MavenProject project)
Builds a GAV object from the given MavenProject object.- Parameters:
project- the project to extract info from- Returns:
- a new GAV object
-
from
public static GAV from(org.apache.maven.model.Model model)
Builds a GAV object from the given Model object.- Parameters:
model- the project model to extract info from- Returns:
- a new GAV object
-
from
public static GAV from(org.apache.maven.model.Parent parent)
Builds a GAV object from the given Parent object.- Parameters:
parent- the parent to extract info from- Returns:
- a new GAV object
-
-