hudson.maven
Class ModuleName
java.lang.Object
hudson.maven.ModuleName
- All Implemented Interfaces:
- Serializable, Comparable<ModuleName>
public class ModuleName
- extends Object
- implements Comparable<ModuleName>, Serializable
Version independent name of a Maven project. GroupID+artifactId.
- Author:
- Kohsuke Kawaguchi
- See Also:
ModuleDependency
,
Serialized Form
groupId
public final String groupId
artifactId
public final String artifactId
ModuleName
public ModuleName(String groupId,
String artifactId)
ModuleName
public ModuleName(org.apache.maven.execution.ExecutionEvent event)
ModuleName
public ModuleName(org.apache.maven.project.MavenProject project)
ModuleName
public ModuleName(org.apache.maven.model.Plugin plugin)
ModuleName
public ModuleName(org.apache.maven.model.ReportPlugin plugin)
ModuleName
public ModuleName(org.apache.maven.model.Extension ext)
ModuleName
public ModuleName(org.apache.maven.model.Dependency dep)
toString
public String toString()
- Returns the "groupId:artifactId" form.
- Overrides:
toString
in class Object
toFileSystemName
public String toFileSystemName()
- Returns the "groupId$artifactId" form,
which is safe for the use as a file name, unlike
toString()
.
fromFileSystemName
public static ModuleName fromFileSystemName(String n)
fromString
public static ModuleName fromString(String n)
isValid
public static boolean isValid(String n)
- Checks if the given name is valid module name string format
created by
toString()
.
equals
public boolean equals(Object o)
- Overrides:
equals
in class Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
compareTo
public int compareTo(ModuleName that)
- Specified by:
compareTo
in interface Comparable<ModuleName>
Copyright © 2004-2013. All Rights Reserved.