Package org.apache.ivy.plugins.parser.m2
Class PomReader
java.lang.Object
org.apache.ivy.plugins.parser.m2.PomReader
Provides the method to read some data out of the DOM tree of a pom file.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final class
class
class
class
class
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private final Element
private static final String
private static final String
private static final String
private static final String
private static final String
private final Element
private static final String
private static final String
private static final String
private static final String
private static final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetAllChilds
(Element parent) private List<PomReader.PomDependencyData>
getDependencies
(Element parent) private List<PomDependencyMgt>
getDependencyMgt
(Element parent) private static Element
getFirstChildElement
(Element parentElem, String name) private static String
getFirstChildText
(Element parentElem, String name) License[]
private List<PomReader.PomPluginElement>
getPlugins
(Element parent) getProperties
(Element parent) private static String
getTextContent
(Element element) boolean
private String
replaceProps
(String val) void
setProperty
(String prop, String val) Add a property if not yet set and value is not null.
-
Field Details
-
PROFILES_ELEMENT
- See Also:
-
PACKAGING
- See Also:
-
DEPENDENCY
- See Also:
-
DEPENDENCIES
- See Also:
-
DEPENDENCY_MGT
- See Also:
-
PROJECT
- See Also:
-
MODEL
- See Also:
-
GROUP_ID
- See Also:
-
ARTIFACT_ID
- See Also:
-
VERSION
- See Also:
-
DESCRIPTION
- See Also:
-
HOMEPAGE
- See Also:
-
LICENSES
- See Also:
-
LICENSE
- See Also:
-
LICENSE_NAME
- See Also:
-
LICENSE_URL
- See Also:
-
PARENT
- See Also:
-
SCOPE
- See Also:
-
CLASSIFIER
- See Also:
-
OPTIONAL
- See Also:
-
EXCLUSIONS
- See Also:
-
EXCLUSION
- See Also:
-
DISTRIBUTION_MGT
- See Also:
-
RELOCATION
- See Also:
-
PROPERTIES
- See Also:
-
PLUGINS
- See Also:
-
PLUGIN
- See Also:
-
TYPE
- See Also:
-
PROFILE
- See Also:
-
properties
-
projectElement
-
parentElement
-
-
Constructor Details
-
PomReader
- Throws:
IOException
SAXException
-
-
Method Details
-
hasParent
public boolean hasParent() -
setProperty
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
-
getParentGroupId
-
getArtifactId
-
getParentArtifactId
-
getVersion
-
getParentVersion
-
getPackaging
-
getHomePage
-
getDescription
-
getLicenses
-
getRelocation
-
getDependencies
-
getDependencies
-
getDependencyMgt
-
getDependencyMgt
-
getProfiles
-
getPlugins
-
getPlugins
-
getProperties
-
getPomProperties
- Returns:
- the content of the properties tag into the pom.
-
replaceProps
-
getTextContent
-
getFirstChildText
-
getFirstChildElement
-
getAllChilds
-