@ThreadSafe public final class PomUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static void |
analyzePOM(Dependency dependency,
File pomFile)
Reads in the pom file and adds elements as evidence to the given
dependency.
|
static Model |
readPom(File file)
Reads in the specified POM and converts it to a Model.
|
static Model |
readPom(String path,
JarFile jar)
Retrieves the specified POM from a jar file and converts it to a Model.
|
public static Model readPom(File file) throws AnalysisException
file - the pom.xml fileAnalysisException - is thrown if there is an exception extracting
or parsing the POM Model objectpublic static Model readPom(String path, JarFile jar) throws AnalysisException
path - the path to the pom.xml file within the jar filejar - the jar file to extract the pom fromAnalysisException - is thrown if there is an exception extracting
or parsing the POM Model objectpublic static void analyzePOM(Dependency dependency, File pomFile) throws AnalysisException
dependency - the dependency being analyzedpomFile - the pom file to readAnalysisException - is thrown if there is an exception parsing the
pomCopyright © 2012–2020 OWASP. All rights reserved.