Optimized project selection for getProjectMetadata

Test: m compliance_sbom

Change-Id: I9e60b7e138a4fca74170954d8bb83862677e750f
This commit is contained in:
Ibrahim Kanouche
2022-11-03 00:43:12 +00:00
parent 88b02afbf0
commit a68ed086ab
2 changed files with 31 additions and 3 deletions

View File

@@ -58,6 +58,11 @@ func (pm *ProjectMetadata) String() string {
return fmt.Sprintf("project: %q\n%s", pm.project, pm.proto.String())
}
// Project returns the path to the directory containing the METADATA file
func (pm *ProjectMetadata) Project() string {
return pm.project
}
// ProjectName returns the name of the project.
func (pm *ProjectMetadata) Name() string {
return pm.proto.GetName()