Add some documentation and simplify data model.

Bug: 245562496

Test: m droid
Change-Id: Iae757a5767522e0734abbe3840ea0939620197e7
This commit is contained in:
Bob Badour
2022-10-28 12:06:08 -07:00
parent 904dd87a75
commit 43daade15f
10 changed files with 143 additions and 86 deletions

View File

@@ -300,23 +300,6 @@ func (tn *TargetNode) PackageName() string {
return tn.proto.GetPackageName()
}
// ModuleTypes returns the list of module types implementing the target.
// (unordered)
//
// In an ideal world, only 1 module type would implement each target, but the
// interactions between Soong and Make for host versus product and for a
// variety of architectures sometimes causes multiple module types per target
// (often a regular build target and a prebuilt.)
func (tn *TargetNode) ModuleTypes() []string {
return append([]string{}, tn.proto.ModuleTypes...)
}
// ModuleClasses returns the list of module classes implementing the target.
// (unordered)
func (tn *TargetNode) ModuleClasses() []string {
return append([]string{}, tn.proto.ModuleClasses...)
}
// Projects returns the projects defining the target node. (unordered)
//
// In an ideal world, only 1 project defines a target, but the interaction
@@ -326,14 +309,6 @@ func (tn *TargetNode) Projects() []string {
return append([]string{}, tn.proto.Projects...)
}
// LicenseKinds returns the list of license kind names for the module or
// target. (unordered)
//
// e.g. SPDX-license-identifier-MIT or legacy_proprietary
func (tn *TargetNode) LicenseKinds() []string {
return append([]string{}, tn.proto.LicenseKinds...)
}
// LicenseConditions returns a copy of the set of license conditions
// originating at the target. The values that appear and how each is resolved
// is a matter of policy. (unordered)