Package org.apache.ivy.plugins.parser.m2
Class PomReader
- java.lang.Object
-
- org.apache.ivy.plugins.parser.m2.PomReader
-
public class PomReader extends java.lang.ObjectProvides the method to read some data out of the DOM tree of a pom file.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classPomReader.PomDependencyDataclassPomReader.PomDependencyMgtElementclassPomReader.PomPluginElementclassPomReader.PomProfileElement
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetArtifactId()java.util.List<PomReader.PomDependencyData>getDependencies()java.util.List<PomDependencyMgt>getDependencyMgt()java.lang.StringgetDescription()java.lang.StringgetGroupId()java.lang.StringgetHomePage()License[]getLicenses()java.lang.StringgetPackaging()java.lang.StringgetParentArtifactId()java.lang.StringgetParentGroupId()java.lang.StringgetParentVersion()java.util.List<PomReader.PomPluginElement>getPlugins()java.util.Map<java.lang.String,java.lang.String>getPomProperties()java.util.List<PomReader.PomProfileElement>getProfiles()ModuleRevisionIdgetRelocation()java.lang.StringgetVersion()booleanhasParent()voidsetProperty(java.lang.String prop, java.lang.String val)Add a property if not yet set and value is not null.
-
-
-
Constructor Detail
-
PomReader
public PomReader(java.net.URL descriptorURL, Resource res) throws java.io.IOException, org.xml.sax.SAXException- Throws:
java.io.IOExceptionorg.xml.sax.SAXException
-
-
Method Detail
-
hasParent
public boolean hasParent()
-
setProperty
public void setProperty(java.lang.String prop, java.lang.String val)Add a property if not yet set and value is not null. This guarantees that property keeps the first value that is put on it and that the properties are never null.- Parameters:
prop- Stringval- String
-
getGroupId
public java.lang.String getGroupId()
-
getParentGroupId
public java.lang.String getParentGroupId()
-
getArtifactId
public java.lang.String getArtifactId()
-
getParentArtifactId
public java.lang.String getParentArtifactId()
-
getVersion
public java.lang.String getVersion()
-
getParentVersion
public java.lang.String getParentVersion()
-
getPackaging
public java.lang.String getPackaging()
-
getHomePage
public java.lang.String getHomePage()
-
getDescription
public java.lang.String getDescription()
-
getLicenses
public License[] getLicenses()
-
getRelocation
public ModuleRevisionId getRelocation()
-
getDependencies
public java.util.List<PomReader.PomDependencyData> getDependencies()
-
getDependencyMgt
public java.util.List<PomDependencyMgt> getDependencyMgt()
-
getProfiles
public java.util.List<PomReader.PomProfileElement> getProfiles()
-
getPlugins
public java.util.List<PomReader.PomPluginElement> getPlugins()
-
getPomProperties
public java.util.Map<java.lang.String,java.lang.String> getPomProperties()
- Returns:
- the content of the properties tag into the pom.
-
-