summaryrefslogtreecommitdiff
path: root/java/droiddoc.go
diff options
context:
space:
mode:
author Paul Duffin <paulduffin@google.com> 2020-11-09 17:36:42 +0000
committer Paul Duffin <paulduffin@google.com> 2020-11-10 13:55:17 +0000
commita3cb6cf2e54551c01b1cec135a162532e044b19e (patch)
tree872c6acc9ac3c88c71376fbd8a46dd16bed1ad73 /java/droiddoc.go
parent37fa489a9e959444f21c08a198c5f120b31d6116 (diff)
Remove support for droidstubs in sdk/module_exports
The droidstubs support in sdk/module_exports was a temporary measure to work around the fact that some APIs were being defined by direct use of droidstubs instead of java_sdk_library. This change removes that support as those APIs have all been switched from droidstubs to use java_sdk_library so droidstubs support is no longer needed. Bug: 168301990 Test: m nothing Change-Id: I3517bed29b030438a0423a6cb8c248992a988222
Diffstat (limited to 'java/droiddoc.go')
-rw-r--r--java/droiddoc.go55
1 files changed, 0 insertions, 55 deletions
diff --git a/java/droiddoc.go b/java/droiddoc.go
index 1e09d6474..c7a27c2a4 100644
--- a/java/droiddoc.go
+++ b/java/droiddoc.go
@@ -19,7 +19,6 @@ import (
"path/filepath"
"strings"
- "github.com/google/blueprint"
"github.com/google/blueprint/proptools"
"android/soong/android"
@@ -30,16 +29,6 @@ import (
func init() {
RegisterDocsBuildComponents(android.InitRegistrationContext)
RegisterStubsBuildComponents(android.InitRegistrationContext)
-
- // Register sdk member type.
- android.RegisterSdkMemberType(&droidStubsSdkMemberType{
- SdkMemberTypeBase: android.SdkMemberTypeBase{
- PropertyName: "stubs_sources",
- // stubs_sources can be used with sdk to provide the source stubs for APIs provided by
- // the APEX.
- SupportsSdk: true,
- },
- })
}
func RegisterDocsBuildComponents(ctx android.RegistrationContext) {
@@ -1829,47 +1818,3 @@ func PrebuiltStubsSourcesFactory() android.Module {
InitDroiddocModule(module, android.HostAndDeviceSupported)
return module
}
-
-type droidStubsSdkMemberType struct {
- android.SdkMemberTypeBase
-}
-
-func (mt *droidStubsSdkMemberType) AddDependencies(mctx android.BottomUpMutatorContext, dependencyTag blueprint.DependencyTag, names []string) {
- mctx.AddVariationDependencies(nil, dependencyTag, names...)
-}
-
-func (mt *droidStubsSdkMemberType) IsInstance(module android.Module) bool {
- _, ok := module.(*Droidstubs)
- return ok
-}
-
-func (mt *droidStubsSdkMemberType) AddPrebuiltModule(ctx android.SdkMemberContext, member android.SdkMember) android.BpModule {
- return ctx.SnapshotBuilder().AddPrebuiltModule(member, "prebuilt_stubs_sources")
-}
-
-func (mt *droidStubsSdkMemberType) CreateVariantPropertiesStruct() android.SdkMemberProperties {
- return &droidStubsInfoProperties{}
-}
-
-type droidStubsInfoProperties struct {
- android.SdkMemberPropertiesBase
-
- StubsSrcJar android.Path
-}
-
-func (p *droidStubsInfoProperties) PopulateFromVariant(ctx android.SdkMemberContext, variant android.Module) {
- droidstubs := variant.(*Droidstubs)
- p.StubsSrcJar = droidstubs.stubsSrcJar
-}
-
-func (p *droidStubsInfoProperties) AddToPropertySet(ctx android.SdkMemberContext, propertySet android.BpPropertySet) {
- if p.StubsSrcJar != nil {
- builder := ctx.SnapshotBuilder()
-
- snapshotRelativeDir := filepath.Join("java", ctx.Name()+"_stubs_sources")
-
- builder.UnzipToSnapshot(p.StubsSrcJar, snapshotRelativeDir)
-
- propertySet.AddProperty("srcs", []string{snapshotRelativeDir})
- }
-}