mirror of
https://github.com/anchore/syft.git
synced 2026-10-30 14:02:26 +01:00
Co-authored-by: Christopher Phillips <christopher.phillips@anchore.com>
18 lines
536 B
Go
18 lines
536 B
Go
package java
|
|
|
|
import "github.com/anchore/syft/syft/pkg/cataloger/common"
|
|
|
|
const javaPomCataloger = "java-pom-cataloger"
|
|
|
|
// NewJavaPomCataloger returns a cataloger capable of parsing
|
|
// dependencies from a pom.xml file.
|
|
// Pom files list dependencies that maybe not be locally installed yet.
|
|
func NewJavaPomCataloger() *common.GenericCataloger {
|
|
globParsers := make(map[string]common.ParserFn)
|
|
|
|
// java project files
|
|
globParsers[pomXMLDirGlob] = parserPomXML
|
|
|
|
return common.NewGenericCataloger(nil, globParsers, javaPomCataloger)
|
|
}
|