use of com.synopsys.integration.detectable.detectables.go.vendr.parse.VndrParser in project synopsys-detect by blackducksoftware.
the class GoVndrExtractor method extract.
public Extraction extract(File vndrConfig) {
try {
VndrParser vndrParser = new VndrParser(externalIdFactory);
List<String> vendorConfContents = Files.readAllLines(vndrConfig.toPath(), StandardCharsets.UTF_8);
logger.debug(String.join("\n", vendorConfContents));
DependencyGraph dependencyGraph = vndrParser.parseVendorConf(vendorConfContents);
CodeLocation codeLocation = new CodeLocation(dependencyGraph);
return new Extraction.Builder().success(codeLocation).build();
} catch (Exception e) {
return new Extraction.Builder().exception(e).build();
}
}
Aggregations