org.rhq.core.util.maven
Class MavenArtifactProperties
java.lang.Object
org.rhq.core.util.maven.MavenArtifactProperties
public class MavenArtifactProperties
- extends Object
- Author:
- Ian Springer
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getGroupId
public String getGroupId()
getArtifactId
public String getArtifactId()
getVersion
public String getVersion()
getProperty
public String getProperty(String propName)
getPropertyNames
public Set<String> getPropertyNames()
getInstance
@Nullable
public static MavenArtifactProperties getInstance(String groupId,
String artifactId)
throws MavenArtifactNotFoundException
- Returns a MavenArtifactProperties for the Maven artifact with the specified group id and artifact id.
First tries to load the pom.properties file for the artifact using the context class loader. If that
fails, then tries to load it using our class loader.
- Parameters:
groupId - the group id of the Maven artifactartifactId - the artifact id of the Maven artifact
- Returns:
- a MavenArtifactProperties for the Maven artifact with the specified group id and artifact id
- Throws:
MavenArtifactNotFoundException - if a pom.properties file for the artifact could not be found in the context
class loader or in our class loader
getInstance
@Nullable
public static MavenArtifactProperties getInstance(String groupId,
String artifactId,
ClassLoader classLoader)
throws MavenArtifactNotFoundException
- Returns a MavenArtifactProperties for the Maven artifact with the specified group id and artifact id.
Tries to load the pom.properties file for the artifact using the specified class loader.
- Parameters:
groupId - the group id of the Maven artifactartifactId - the artifact id of the Maven artifactclassLoader - the class loader in which to look for the artifact
- Returns:
- a MavenArtifactProperties for the Maven artifact with the specified group id and artifact id
- Throws:
MavenArtifactNotFoundException - if a pom.properties file for the artifact could not be found in the
specified class loader
Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.